Skip to content
This repository has been archived by the owner on Sep 16, 2023. It is now read-only.

docs: removed default model comment, added comment to test #997

Merged
merged 1 commit into from Dec 10, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Expand Up @@ -46,7 +46,6 @@ static void createModel(String projectId, String datasetId, String displayName)
try (AutoMlClient client = AutoMlClient.create()) {
// A resource that represents Google Cloud Platform location.
LocationName projectLocation = LocationName.of(projectId, "us-central1");
// Leave model unset to use the default base model provided by Google
TranslationModelMetadata translationModelMetadata =
TranslationModelMetadata.newBuilder().build();
Model model =
Expand Down
Expand Up @@ -76,8 +76,12 @@ public void testTranslateCreateModel() {
String.format("test_%s", UUID.randomUUID().toString().replace("-", "_").substring(0, 26));
TranslateCreateModel.createModel(PROJECT_ID, DATASET_ID, modelName);
String got = bout.toString();
// After setting DATASET_ID, change line below to
// assertThat(got).contains("Training started...");
assertThat(got).contains("Dataset does not exist");
} catch (IOException | ExecutionException | InterruptedException e) {
// After setting DATASET_ID, change line below to
// assertThat(e.getMessage()).contains("Training started...");
assertThat(e.getMessage()).contains("Dataset does not exist");
}
}
Expand Down