diff options
author | Kris Maglione <maglione.k@gmail.com> | 2011-01-27 15:12:33 -0500 |
---|---|---|
committer | Kris Maglione <maglione.k@gmail.com> | 2011-01-27 15:12:33 -0500 |
commit | d16c0b0d06a5a4c308a03928328ba504a399ecd9 (patch) | |
tree | c6d49b047ad09d7f188139f2cf242ffd5c82f4eb /common/tests/functional/testShellCommands.js | |
parent | 2c3fd51812a3f3626f519aa7bd6b4b22e031a666 (diff) | |
download | pentadactyl-d16c0b0d06a5a4c308a03928328ba504a399ecd9.tar.gz |
Back out most of the changes accidentally merged from key-processing.
--HG--
extra : rebase_source : a00510584f7e13917f8496e15b7dd36852d98ea7
Diffstat (limited to 'common/tests/functional/testShellCommands.js')
-rw-r--r-- | common/tests/functional/testShellCommands.js | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/common/tests/functional/testShellCommands.js b/common/tests/functional/testShellCommands.js new file mode 100644 index 00000000..0a4ae7c1 --- /dev/null +++ b/common/tests/functional/testShellCommands.js @@ -0,0 +1,33 @@ +var dactyllib = require("dactyl"); + +var setupModule = function (module) { + controller = mozmill.getBrowserController(); + dactyl = new dactyllib.Controller(controller); +}; + +var teardownTest = function (test) { + dactyl.closeMessageWindow(); +}; + +var testRunCommand_ExecutingOutputCommand_OutputDisplayed = function () { + const EXPECTED_OUTPUT = "foobar"; + const COMMAND = "run echo " + EXPECTED_OUTPUT; + + dactyl.runExCommand(COMMAND); + + dactyl.assertMessageWindow(RegExp(EXPECTED_OUTPUT)); +}; + +var testRunCommand_RepeatArg_LastCommandRepeated = function () { + const EXPECTED_OUTPUT = /foobar$/; // XXX + const COMMAND = "run echo 'foobar'"; + const REPEAT_COMMAND = "run!"; + + dactyl.runExCommand(COMMAND); + dactyl.closeMessageWindow(); + dactyl.runExCommand(REPEAT_COMMAND); + + dactyl.assertMessageWindow(EXPECTED_OUTPUT); +}; + +// vim: sw=4 ts=8 et: |