removed REGEXP_IN_MATCH regex to make it flexible to use with plugins (#10476)

* dynamic regex generation for 'STATUS' and 'IN' ddropdown
This commit is contained in:
Ahmed Gagan
2020-09-01 18:03:05 +05:30
committed by GitHub
parent 34478760b2
commit b14098ce28
2 changed files with 50 additions and 3 deletions

View File

@@ -290,6 +290,34 @@ QUnit.test("update status through advanced search ui", async assert => {
);
});
QUnit.test(
"doesn't update status filter header if wrong value entered through searchbox",
async assert => {
const statusSelector = selectKit(
".search-advanced-options .select-kit#status"
);
await visit("/search");
await fillIn(".search-query", "status:none");
assert.equal(statusSelector.header().label(), "any", 'has "any" populated');
}
);
QUnit.test(
"doesn't update in filter header if wrong value entered through searchbox",
async assert => {
const inSelector = selectKit(".search-advanced-options .select-kit#in");
await visit("/search");
await fillIn(".search-query", "in:none");
assert.equal(inSelector.header().label(), "any", 'has "any" populated');
}
);
QUnit.test("update post time through advanced search ui", async assert => {
await visit("/search?expanded=true&q=after:2018-08-22");