Create ES index in search_test before relying on it#3303
Merged
Conversation
Codecov Report
@@ Coverage Diff @@
## master #3303 +/- ##
=======================================
Coverage 98.52% 98.52%
=======================================
Files 113 113
Lines 3390 3390
=======================================
Hits 3340 3340
Misses 50 50 Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
2733ba8 to
e9cd31a
Compare
Contributor
Author
|
As discussed in #3307, this blocks running individual files/tests without ES running. Is that a worthwhile trade-off or should I just fix the places where the index needs to be created first? We will just need to keep on top of which tests need the index and add that line to the setup. |
Contributor
|
Can you please revert change in test helper and just create index where needed for now? |
Although usually this worked, it could lead to order dependent failures when the index hadn't been created by another test at some point.
e9cd31a to
2066aa0
Compare
Contributor
Author
|
Done. Thanks for the specific feedback. |
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.
There was an order dependent failure caused by test/integration/search_test.rb using the index without creating it.
We now create the index in that test. Any future tests that need the index should make sure to create it.