-
Notifications
You must be signed in to change notification settings - Fork 47
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
Update unit test for autocomplete suggests fix #104
Update unit test for autocomplete suggests fix #104
Conversation
…ry for Suggestions
app/code/Magento/Elasticsearch/Model/DataProvider/Base/Suggestions.php
Outdated
Show resolved
Hide resolved
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.
Thank you for the update making the new dependencies optional constructor arguments. Now only the removal of the field provider needs to be reversed... sorry for yet another change request, and thanks again for your work!
@Vinai: @kuafucode should have fixed the PR, could you quickly check? can I remove your change-request and approve it? |
* added additional check to ensure autocomplete suggests only searchable terms * updated unitest for search suggest fix * added type casting for isSuggestible * reverted suggestible flag and fixed getSuggestFields method * updated suggest contructor params to avoid bic * updated unit test with new dependency productAttributeCollectionFactory for Suggestions * add fieldProvider back to Suggestions constructor --------- Co-authored-by: Ryan Sun <ryansun@isnweb.com>
* Bugfix: autocomplete suggests nonsearchable terms (#102) * added additional check to ensure autocomplete suggests only searchable terms --------- Co-authored-by: Ryan Sun <ryansun@isnweb.com> * Update unit test for autocomplete suggests fix (#104) * added additional check to ensure autocomplete suggests only searchable terms * updated unitest for search suggest fix * added type casting for isSuggestible * reverted suggestible flag and fixed getSuggestFields method * updated suggest contructor params to avoid bic * updated unit test with new dependency productAttributeCollectionFactory for Suggestions * add fieldProvider back to Suggestions constructor --------- Co-authored-by: Ryan Sun <ryansun@isnweb.com> --------- Co-authored-by: Ryan Sun <ryansun81@gmail.com> Co-authored-by: Ryan Sun <ryansun@isnweb.com>
Description (*)
Since 2.4.7 we noticed search autocomplete would suggest search terms with no result.
here are some more cases of bad search suggestions with sample data package :
Intending to search for "Didi Sports Watch"
"didi" -> suggestion "duti" with no matches
Intending to search for "Bottle"
"bot" -> suggestion for "but" and "boi", the latter bringing no search results
Intending to serach for "Summit
"summ" -> suggestion "seam" and "sued" which bring results but not the watch
Manual testing scenarios (*)