Esempio n. 1
0
 public void testIngestAsync()
 {
     PrecogClient testClient = ServiceStack.CreatePrecogClient(SERVICE, testApiKey);
     IngestOptions options = new CSVIngestOptions();
     options.Async=true;
     IngestResult result = testClient.Ingest(storePath, "blah,\n\n", options);
     //is async, so we don't expect results
     Assert.IsFalse(result.Completed);
 }
Esempio n. 2
0
 public void testIngestCSV()
 {
     PrecogClient testClient = ServiceStack.CreatePrecogClient(SERVICE, testApiKey);
     IngestOptions options = new CSVIngestOptions();
     IngestResult response = testClient.Ingest(storePath, "blah,\n\n", options);
     Assert.AreEqual(1, response.Ingested);
 }
Esempio n. 3
0
 public void testIngestCsvWithOptions()
 {
     PrecogClient testClient = ServiceStack.CreatePrecogClient(SERVICE, testApiKey);
     CSVIngestOptions options = new CSVIngestOptions();
     options.delimiter=",";
     options.quote="'";
     options.escape="\\";
     IngestResult response = testClient.Ingest(storePath, "blah,\n\n", options);
     Assert.AreEqual(1, response.Ingested);
 }