-
Notifications
You must be signed in to change notification settings - Fork 3.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
kv rest api: add remaining range tests #111
Conversation
@cockroachdb/developers |
// Query remaining range. | ||
start, end = 0, 99 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could add another limit here (say 75) which shouldn't interfere with the operation.
LGTM |
t.Errorf("unable to decode JSON into proto.ScanResponse: %v", err) | ||
} | ||
numRows := end - limit | ||
if len(scan.Rows) != numRows { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Another way to verify would be to construct expected results. You might do that via a Scan of the underlying rows directly from the server's db. That way you could set up a list of tests which scan with different start, end and limit keys and then compare the results using !reflect.DeepEqual(results, expResults).
Not necessary to do this--I think these tests are fine. But something to keep in mind.
LGTM |
5c8cddc
to
069fa16
Compare
069fa16
to
079034c
Compare
kv rest api: add remaining range tests
…ive_contains_route Case sensitive contained in logic
No description provided.