Go to the source code of this file.
Functions | |
function | getDefaultScope (aFolderId) |
function | getSelectedScopeButtonId () |
function | queryStringToQuery (aPlaceURI) |
function | resetSearch (aExpectedScopeButtonId) |
function | search (aFolderId, aSearchStr, aExpectedScopeButtonId) |
function | selectScope (aScopeButtonId) |
function | testHelper (aLibraryWin) |
function | test () |
Variables | |
const | TEST_URL = "http://dummy.mozilla.org/" |
var | testCases |
const | bmsvc |
const | histsvc |
var | libraryWin |
function getDefaultScope | ( | aFolderId | ) |
Returns the default search scope for a given folder.
aFolderId | the item ID of a node in the left pane's tree |
Definition at line 132 of file browser_library_search.js.
function getSelectedScopeButtonId | ( | ) |
Returns the ID of the search scope button that is currently checked.
Definition at line 143 of file browser_library_search.js.
function queryStringToQuery | ( | aPlaceURI | ) |
Returns the single nsINavHistoryQuery represented by a given place URI.
aPlaceURI | a URI that represents a single query |
Definition at line 160 of file browser_library_search.js.
function resetSearch | ( | aExpectedScopeButtonId | ) |
Resets the search by clearing the search box's text and ensures that the search scope remains as expected.
aExpectedScopeButtonId | this button should be selected after the reset |
Definition at line 173 of file browser_library_search.js.
function search | ( | aFolderId, | |
aSearchStr, | |||
aExpectedScopeButtonId | |||
) |
Performs a search for a given folder and search string and ensures that the URI of the right pane's content tree is as expected for the folder and search string. Also ensures that the search scope button is as expected after the search.
aFolderId | the item ID of a node in the left pane's tree |
aSearchStr | the search text; may be empty to reset the search |
aExpectedScopeButtonId | after searching the selected scope button should be this |
Definition at line 190 of file browser_library_search.js.
function selectScope | ( | aScopeButtonId | ) |
Clicks the given search scope button if it is enabled.
aScopeButtonId | the button with this ID will be clicked |
Definition at line 251 of file browser_library_search.js.
function test | ( | ) |
function testHelper | ( | aLibraryWin | ) |
test() contains window-launching boilerplate that calls this to really kick things off. Add functions to the testCases array, and this will call them.
aLibraryWin | the Places Library window |
Definition at line 270 of file browser_library_search.js.
const bmsvc |
Definition at line 117 of file browser_library_search.js.
const histsvc |
Definition at line 119 of file browser_library_search.js.
var libraryWin |
Definition at line 121 of file browser_library_search.js.
const TEST_URL = "http://dummy.mozilla.org/" |
Bug 451151 https://bugzilla.mozilla.org/show_bug.cgi?id=451151
Summary: Tests frontend Places Library searching – search, search reset, search scope consistency.
Details: Each test below
Definition at line 63 of file browser_library_search.js.
var testCases |
Definition at line 66 of file browser_library_search.js.