do not return payload as field#1914
Merged
MeirShpilraien merged 6 commits intomasterfrom Mar 24, 2021
Merged
Conversation
filipecosta90
previously approved these changes
Mar 20, 2021
added 2 commits
March 20, 2021 16:45
Author
|
Tests will pass when this will be merged: |
ashtul
approved these changes
Mar 20, 2021
rafie
previously approved these changes
Mar 21, 2021
ashtul
reviewed
Mar 21, 2021
Contributor
ashtul
left a comment
There was a problem hiding this comment.
These tests are for the payload.
| @@ -207,10 +207,10 @@ def testPayload(env): | |||
| for _ in env.retry_with_rdb_reload(): | |||
| waitForIndex(env, 'things') | |||
| res = env.cmd('ft.search', 'things', 'foo') | |||
Contributor
There was a problem hiding this comment.
We should add 'WITHPAYLOAD`
Author
There was a problem hiding this comment.
There is withpayloads right below..
| env.assertEqual(toSortedFlatList(res), toSortedFlatList([1L, 'thing:foo', ['name', 'foo', 'payload', 'stuff']])) | ||
| env.assertEqual(toSortedFlatList(res), toSortedFlatList([1L, 'thing:foo', ['name', 'foo']])) | ||
|
|
||
| res = env.cmd('ft.search', 'things', 'foo', 'withpayloads') |
| for _ in env.retry_with_rdb_reload(): | ||
| waitForIndex(env, 'things') | ||
| res = env.cmd('ft.search', 'things', 'foo') | ||
| env.assertEqual(toSortedFlatList(res), toSortedFlatList([1L, 'thing:foo', ['name', 'foo', 'payload', '\x00\xAB\x20']])) |
| env.assertEqual(toSortedFlatList(res), toSortedFlatList([1L, 'thing:foo', ['name', 'foo']])) | ||
|
|
||
| res = env.cmd('ft.search', 'things', 'foo', 'withpayloads') | ||
| env.assertEqual(toSortedFlatList(res), toSortedFlatList([1L, 'thing:foo', '\x00\xAB\x20', ['name', 'foo', 'payload', '\x00\xAB\x20']])) |
ashtul
previously approved these changes
Mar 21, 2021
Codecov Report
@@ Coverage Diff @@
## master #1914 +/- ##
=======================================
Coverage 80.30% 80.30%
=======================================
Files 148 148
Lines 21503 21504 +1
=======================================
+ Hits 17268 17269 +1
Misses 4235 4235
Continue to review full report at Codecov.
|
Author
ashtul
approved these changes
Mar 24, 2021
Contributor
|
LGTM 👍🏻 |
MeirShpilraien
pushed a commit
that referenced
this pull request
Mar 24, 2021
* do not return payload as field * fix tests * fix tests * fix tests * fix tests Co-authored-by: Rafi Einstein <rafi@redislabs.com>
MeirShpilraien
pushed a commit
that referenced
this pull request
Mar 29, 2021
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.
Uh oh!
There was an error while loading. Please reload this page.