-
-
Notifications
You must be signed in to change notification settings - Fork 58
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
Fixed duplicate timestamps causing pagination test failure #157
Conversation
db_test.go
Outdated
// Old code that caused duplicates: | ||
// doc.Set("timestamp", time.Now()) | ||
|
||
// New code to ensure unique timestamps: |
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.
This comment makes sense, but there is no need to mention about what "old code" was doing
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.
You can leave this one, but rephrase it to not mention "old code"
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.
Thanks for the PR, @ahmed-hossam28. Added some comments.
Thank you @ostafen for your efforts too, I will resolve them. |
…r review feedback.
@ostafen, I have removed the unnecessary comments and the checkUniqueTimestamps function as suggested. |
db_test.go
Outdated
@@ -1507,7 +1507,11 @@ func TestPagedQueryUsingIndex(t *testing.T) { | |||
n := 10003 | |||
for i := 0; i < n; i++ { | |||
doc := d.NewDocument() | |||
doc.Set("timestamp", time.Now()) | |||
|
|||
// doc.Set("timestamp", time.Now()) |
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.
Please remove all the comments
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.
Added some more comments
Thank you @ostafen for your feedback, i updated the comments. |
Looks good now, thanks for your patience! |
No description provided.