public async Task MlProcessing_ModelTraining_ModelPersisted() { var models = Harness.GetDependentFilesExcept(FolderId, FileType.Image, FileType.Tabular, FileType.Pdf); var modelResponse = await JohnApi.GetModelEntityById(models.First()); modelResponse.EnsureSuccessStatusCode(); var modelJson = JToken.Parse(await modelResponse.Content.ReadAsStringAsync()); modelJson.Should().ContainsJson($@" {{ 'id': '{modelJson["id"].ToObject<Guid>()}', 'blob': *EXIST*, 'ownedBy': '{JohnId}', 'createdBy': '{JohnId}', 'createdDateTime': *EXIST*, 'updatedBy': '{JohnId}', 'updatedDateTime': *EXIST*, 'parentId': '{FolderId}', 'name': 'Naive Bayes', 'status': 'Processed', 'version': 11, 'method': 'NaiveBayes', 'className': 'ClassName', 'subSampleSize': '0.2', 'kFold': 4, 'fingerprints': [ {{ 'type': '1', 'size': 1024, 'radius': 3 }}], 'images': *EXIST* }}", new List <string> { "testDatasetSize" }); var modelNodeResponse = await JohnApi.GetNodeById(models.First()); modelNodeResponse.EnsureSuccessStatusCode(); var nodeJson = JToken.Parse(await modelNodeResponse.Content.ReadAsStringAsync()); nodeJson.Should().ContainsJson($@" {{ 'id': '{modelJson["id"].ToObject<Guid>()}', 'blob': *EXIST*, 'type': 'Model', 'ownedBy': '{JohnId}', 'createdBy': '{JohnId}', 'createdDateTime': *EXIST*, 'updatedBy': '{JohnId}', 'updatedDateTime': *EXIST*, 'parentId': '{FolderId}', 'name': 'Naive Bayes', 'status': 'Processed', 'version': 11, 'images': *EXIST* }}"); }
public async Task MlProcessing_ModelTraining_ModelProcessed() { var models = Harness.GetDependentFilesExcept(FolderId, FileType.Image, FileType.Tabular, FileType.Pdf); var modelResponse = await JohnApi.GetModelEntityById(models.First()); modelResponse.EnsureSuccessStatusCode(); var modelJson = JToken.Parse(await modelResponse.Content.ReadAsStringAsync()); modelJson["status"].ToObject <string>().ShouldBeEquivalentTo("Processed"); }