-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
Fix FreeText tests #21922
Fix FreeText tests #21922
Conversation
Resolves #18199
Hello @smitpatel! Because this pull request has the p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (
|
@@ -225,15 +227,15 @@ public void FreeText_through_navigation_with_language_terms() | |||
c => EF.Functions.FreeText(c.Manager.Title, "President", 1033) | |||
&& EF.Functions.FreeText(c.Title, "Inside", 1031) | |||
&& c.FirstName.Contains("Lau")) | |||
.LastOrDefault(); | |||
.FirstOrDefault(); |
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.
I reckon there is only one matching row in the table, but perhaps we should add orderby instead?
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.
Isn't the operator irrelevant here?
What we are testing is translate of FreeText function. So I just added a mix rather than using LastOrDefault everywhere.
@@ -423,16 +425,16 @@ public void Contains_through_navigation() | |||
.Where( | |||
c => EF.Functions.Contains(c.Manager.Title, "President") | |||
&& EF.Functions.Contains(c.Title, "\"Ins*\"")) | |||
.LastOrDefault(); | |||
.FirstOrDefault(); | |||
|
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.
same here
Resolves #18199