Skip to content

Commit

Permalink
Fixing integration tests (opensearch-project#375)
Browse files Browse the repository at this point in the history
* Fixing integration tests

Signed-off-by: Vacha Shah <vachshah@amazon.com>

* Updating the test with a non-exact check

Signed-off-by: Vacha Shah <vachshah@amazon.com>

---------

Signed-off-by: Vacha Shah <vachshah@amazon.com>
Signed-off-by: MarinaRazumovsky <rzm.mrn@gmail.com>
  • Loading branch information
VachaShah authored and MarinaRazumovsky committed Mar 20, 2023
1 parent c54bcdb commit 692cf8e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
- Prevent SPI calls at runtime ([#293](https://github.com/opensearch-project/opensearch-java/pull/293))
- Add support for OpenSearch Serverless ([#339](https://github.com/opensearch-project/opensearch-java/pull/339))
- Fix issue where completion suggestions were failing, due to being parsed as term suggestions ([#107](https://github.com/opensearch-project/opensearch-java/issues/107))
- Fix integration tests ([#375](https://github.com/opensearch-project/opensearch-java/pull/375))

### Deprecated

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
import static java.util.Collections.emptyMap;
import static org.hamcrest.Matchers.notNullValue;
import static org.hamcrest.Matchers.nullValue;
import static org.junit.Assert.assertTrue;

public abstract class AbstractClusterClientIT extends OpenSearchJavaClientTestCase {
public void testClusterPutSettings() throws IOException {
Expand Down Expand Up @@ -95,11 +96,7 @@ public void testClusterUpdateSettingNonExistent() throws IOException {
} catch (OpenSearchException e) {
assertNotNull(e);
assertEquals(e.response().status(), 400);
assertEquals(
e.getMessage(),
"Request failed: [illegal_argument_exception] " +
"transient setting [no_idea_what_you_are_talking_about], not recognized"
);
assertTrue(e.getMessage().contains("transient setting [no_idea_what_you_are_talking_about], not recognized"));
}
}

Expand Down

0 comments on commit 692cf8e

Please sign in to comment.