mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-21 15:27:57 +01:00
Back out most of the changes accidentally merged from key-processing.
--HG-- extra : rebase_source : a00510584f7e13917f8496e15b7dd36852d98ea7
This commit is contained in:
34
common/tests/functional/testVersionCommand.js
Normal file
34
common/tests/functional/testVersionCommand.js
Normal file
@@ -0,0 +1,34 @@
|
||||
var dactyllib = require("dactyl");
|
||||
|
||||
var setupModule = function (module) {
|
||||
controller = mozmill.getBrowserController();
|
||||
dactyl = new dactyllib.Controller(controller);
|
||||
};
|
||||
|
||||
var setupTest = function (test) {
|
||||
dactyl.closeMessageWindow();
|
||||
};
|
||||
|
||||
var testVersionCommand_NoArg_VersionStringDisplayed = function () {
|
||||
const EXPECTED_OUTPUT = RegExp(dactyl.applicationName + ".+ (.+) running on:.+"); // XXX
|
||||
|
||||
dactyl.runExCommand("version");
|
||||
|
||||
dactyl.assertMessageWindow(EXPECTED_OUTPUT);
|
||||
};
|
||||
|
||||
var testVersionCommand_BangArg_HostAppVersionPageDisplayed = function () {
|
||||
const EXPECTED_URL = "about:";
|
||||
const EXPECTED_TITLE = "About:";
|
||||
const BLANK_PAGE_URL = "about:blank";
|
||||
|
||||
controller.open(BLANK_PAGE_URL);
|
||||
controller.waitForPageLoad(controller.tabs.activeTab);
|
||||
dactyl.runExCommand("version!");
|
||||
controller.waitForPageLoad(controller.tabs.activeTab);
|
||||
|
||||
controller.assert(function () controller.tabs.activeTab.location.href === EXPECTED_URL);
|
||||
controller.assert(function () controller.tabs.activeTab.title === EXPECTED_TITLE);
|
||||
};
|
||||
|
||||
// vim: sw=4 ts=8 et:
|
||||
Reference in New Issue
Block a user