From 3272c49bbbdd25f53ebca812b84eceaaa160bd84 Mon Sep 17 00:00:00 2001 From: Lawrence Qiu Date: Tue, 30 Aug 2022 09:42:32 -0400 Subject: [PATCH] fix: Update IT Test Case Results (#976) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly: - [ ] Make sure to open an issue as a [bug/issue](https://github.com/googleapis/java-vision/issues/new/choose) before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea - [ ] Ensure the tests and linter pass - [ ] Code coverage does not decrease (if any source code was changed) - [ ] Appropriate docs were updated (if necessary) Fixes [#968](https://github.com/googleapis/java-vision/issues/968) and [#967](https://github.com/googleapis/java-vision/issues/967) ☕️ If you write sample code, please follow the [samples format]( https://github.com/GoogleCloudPlatform/java-docs-samples/blob/main/SAMPLE_FORMAT.md). --- README.md | 6 +++--- .../java/com/google/cloud/vision/it/ITSystemTest.java | 8 +++----- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 35199363b..a18aa250d 100644 --- a/README.md +++ b/README.md @@ -50,20 +50,20 @@ If you are using Maven without BOM, add this to your dependencies: If you are using Gradle 5.x or later, add this to your dependencies: ```Groovy -implementation platform('com.google.cloud:libraries-bom:26.0.0') +implementation platform('com.google.cloud:libraries-bom:26.1.0') implementation 'com.google.cloud:google-cloud-vision' ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-vision:3.0.1' +implementation 'com.google.cloud:google-cloud-vision:3.1.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-vision" % "3.0.1" +libraryDependencies += "com.google.cloud" % "google-cloud-vision" % "3.1.0" ``` ## Authentication diff --git a/google-cloud-vision/src/test/java/com/google/cloud/vision/it/ITSystemTest.java b/google-cloud-vision/src/test/java/com/google/cloud/vision/it/ITSystemTest.java index 9ba1ee404..517fc799a 100644 --- a/google-cloud-vision/src/test/java/com/google/cloud/vision/it/ITSystemTest.java +++ b/google-cloud-vision/src/test/java/com/google/cloud/vision/it/ITSystemTest.java @@ -473,7 +473,7 @@ public void detectSafeSearchGcsTest() throws IOException { } @Test - public void detectWebEntitiesGcsTest() throws IOException { + public void detectWebEntitiesGcsTest() { ImageSource imgSource = ImageSource.newBuilder().setGcsImageUri(SAMPLE_BUCKET + "landmark/pofa.jpg").build(); Image img = Image.newBuilder().setSource(imgSource).build(); @@ -492,7 +492,7 @@ public void detectWebEntitiesGcsTest() throws IOException { actual.add(entity.getDescription()); } } - assertThat(actual).contains("The Palace Of Fine Arts"); + assertThat(actual).contains("Palace of Fine Arts"); } @Test @@ -547,14 +547,12 @@ public void detectWebEntitiesIncludeGeoResultsGcsTest() { imageAnnotatorClient.batchAnnotateImages(ImmutableList.of(request)); List responses = response.getResponsesList(); List actual = new ArrayList<>(); - System.out.println("WebEntitiesGeo SIZE"); - System.out.println(actual.size()); for (AnnotateImageResponse imgResponse : responses) { for (WebDetection.WebEntity entity : imgResponse.getWebDetection().getWebEntitiesList()) { actual.add(entity.getDescription()); } } - assertThat(actual).contains("The Palace Of Fine Arts"); + assertThat(actual).contains("Palace of Fine Arts"); } @Test