Port more OldIndexBackwardsCompatibilityIT tests to full cluster restart qa tests#25173
Conversation
There was a problem hiding this comment.
I'd go with assertThat(totalHits, greaterThanOrEqualTo(1)) because it is going to produce a nice error message.
There was a problem hiding this comment.
sure, on the other hand I try to use junit's Assert.* methods where possible. I'm not a big fan of using both test libraries in the same test case. But in this case it does improve readability.
There was a problem hiding this comment.
I go the other way: I use junit's assert when it produces goot error messages and hamcrest otherwise. Whatever works is cool.
There was a problem hiding this comment.
Map<?, ?> bestHit = (Map<?, ?>) ... will probably work and won't require the SuppressWarnings.
There was a problem hiding this comment.
I do this a bit in other places. Do you want to convert? I didn't feel the need to make this but it is shorter so I'm fine with it.
There was a problem hiding this comment.
I feel like assertNewReplicasWork should be in its own test. It doesn't have much to do with searching, I don't think.
There was a problem hiding this comment.
I just like the idea of keeping the complexity around searching in the search test. That way the test for new replicas doesn't need fancy documents. It doesn't have fancy documents so we can be sure fancy documents have nothing to do with the test.
0e1372f to
21ab817
Compare
|
@nik9000 Thanks! I've update the PR. |
21ab817 to
cf2f802
Compare
…ter restart qa tests. Relates to elastic#24939
cf2f802 to
7b75b37
Compare
* master: [Test] restore BWC for parent-join now that the new mapping format is in 5.x Add a section named "relations" in the ParentJoinFieldMapper (elastic#25248) test: Ported more OldIndexBackwardsCompatibilityIT tests to full cluster restart qa tests. (elastic#25173) fix: Sort Processor does not have proper behavior with targetField (elastic#25237) Allow reader wrappers to have different live docs but the same cache key.
…y-context * 'master' of github.com:elastic/elasticsearch: (21 commits) [DOCS] Clarify expected availability of HDFS for the HDFS Repository (elastic#25220) Remove some redundant 140 character checkstyle suppressions [Docs] more fix for the parent-join docs [Docs] Fix cross reference for parent-join field More advices around search speed and disk usage. (elastic#25252) Add documentation for the new parent-join field (elastic#25227) [analysis-icu] Allow setting unicodeSetFilter (elastic#20814) Introduce translog size and age based retention policies (elastic#25147) Add needs methods for specific variables to Painless script context factories. (elastic#25267) Improves snapshot logging and snapshoth deletion error handling (elastic#25264) Add unit test for PathHierarchyTokenizerFactory (elastic#24984) Deprecate tribe service Moved more token filters to analysis-common module. [Test] Make sure that SearchAfterSortedDocQueryTests uses a single threaded searcher [DOCS] Defined es-test-dir and plugins-examples-dir in index.asciidoc. (elastic#25232) Test fix - removed superfluous assertion (elastic#25247) [Test] restore BWC for parent-join now that the new mapping format is in 5.x Add a section named "relations" in the ParentJoinFieldMapper (elastic#25248) test: Ported more OldIndexBackwardsCompatibilityIT tests to full cluster restart qa tests. (elastic#25173) fix: Sort Processor does not have proper behavior with targetField (elastic#25237) ...
Relates to #24939