mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
Migrate search drop down to menu-panel component.
This commit is contained in:
@@ -23,15 +23,8 @@ test("header", () => {
|
||||
// Search
|
||||
click("#search-button");
|
||||
andThen(() => {
|
||||
ok(exists("#search-dropdown:visible"), "after clicking a button search box opens");
|
||||
not(exists("#search-dropdown .heading"), "initially, immediately after opening, search box is empty");
|
||||
ok(exists(".search-menu:visible"), "after clicking a button search box opens");
|
||||
not(exists(".search-menu .heading"), "initially, immediately after opening, search box is empty");
|
||||
});
|
||||
|
||||
// Perform Search
|
||||
// TODO how do I fix the fixture to be a POST instead of a GET @eviltrout
|
||||
// fillIn("#search-term", "hello");
|
||||
// andThen(() => {
|
||||
// ok(exists("#search-dropdown .heading"), "when user completes a search, search box shows search results");
|
||||
// equal(find("#search-dropdown .results a:first").attr("href"), "/t/hello-bar-integration-issues/17638", "there is a search result");
|
||||
// });
|
||||
});
|
||||
|
||||
@@ -8,11 +8,11 @@ test("search", (assert) => {
|
||||
|
||||
andThen(() => {
|
||||
assert.ok(exists('#search-term'), 'it shows the search bar');
|
||||
assert.ok(!exists('#search-dropdown .results ul li'), 'no results by default');
|
||||
assert.ok(!exists('.search-menu .results ul li'), 'no results by default');
|
||||
});
|
||||
|
||||
fillIn('#search-term', 'dev');
|
||||
andThen(() => {
|
||||
assert.ok(exists('#search-dropdown .results ul li'), 'it shows results');
|
||||
assert.ok(exists('.search-menu .results ul li'), 'it shows results');
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user