TEST: avoid generating duplicate multiple fields#27080
Merged
dnhatn merged 2 commits intoelastic:masterfrom Oct 23, 2017
Merged
TEST: avoid generating duplicate multiple fields#27080dnhatn merged 2 commits intoelastic:masterfrom
dnhatn merged 2 commits intoelastic:masterfrom
Conversation
Multifields parser does not allow duplicate values, however the MultiFieldTests may produce duplicate field values. See https://elasticsearch-ci.elastic.co/job/elastic+elasticsearch+master+release-tests/132/console.
jasontedor
approved these changes
Oct 23, 2017
| // can to unnecessary re-syncing of the mappings between the local instance and cluster state | ||
| public void testMultiFieldsInConsistentOrder() throws Exception { | ||
| String[] multiFieldNames = new String[randomIntBetween(2, 10)]; | ||
| HashSet<String> seenFields = new HashSet<>(); |
Member
There was a problem hiding this comment.
Let's type the left-hand side as Set<String>.
Member
Author
There was a problem hiding this comment.
Ah, I prefer to have a concrete type for local variables. I will push the change.
Member
There was a problem hiding this comment.
I think the less-specific types are better when you can get away with them so that you do not come to rely on implementation details of the concrete type.
Member
Author
|
Thanks @jasontedor, your comment is addressed. |
jasontedor
added a commit
to jasontedor/elasticsearch
that referenced
this pull request
Oct 24, 2017
* master: Timed runnable should delegate to abstract runnable Expose adaptive replica selection stats in /_nodes/stats API Remove dangerous `ByteBufStreamInput` methods (elastic#27076) Blacklist Gradle 4.2 and above Remove duplicated test (elastic#27091) Update numbers to reflect 4-byte UTF-8-encoded characters (elastic#27083) test: avoid generating duplicate multiple fields (elastic#27080) Reduce the default number of cached queries. (elastic#26949) removed unused import ingest: date processor should not fail if timestamp is specified as json number
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Multifields parser does not allow duplicate values, however the
MultiFieldTestsmay produce duplicate field values.See https://elasticsearch-ci.elastic.co/job/elastic+elasticsearch+master+release-tests/132/console