Add spec helper.
Project: http://git-wip-us.apache.org/repos/asf/incubator-cordova-app-hello-world/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-cordova-app-hello-world/commit/22fa9055 Tree: http://git-wip-us.apache.org/repos/asf/incubator-cordova-app-hello-world/tree/22fa9055 Diff: http://git-wip-us.apache.org/repos/asf/incubator-cordova-app-hello-world/diff/22fa9055 Branch: refs/heads/master Commit: 22fa90553e1174c64e8928d89ea6f126085709e2 Parents: 233d995 Author: Michael Brooks <mich...@michaelbrooks.ca> Authored: Thu Jul 12 23:04:09 2012 -0700 Committer: Michael Brooks <mich...@michaelbrooks.ca> Committed: Thu Jul 12 23:04:09 2012 -0700 ---------------------------------------------------------------------- www/spec/helper.js | 11 +++++++++++ 1 files changed, 11 insertions(+), 0 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-cordova-app-hello-world/blob/22fa9055/www/spec/helper.js ---------------------------------------------------------------------- diff --git a/www/spec/helper.js b/www/spec/helper.js new file mode 100644 index 0000000..3bc58a8 --- /dev/null +++ b/www/spec/helper.js @@ -0,0 +1,11 @@ +beforeEach(function() { + document.getElementById('stage').innerHTML = ''; +}); + +var helper = { + trigger: function(obj, name) { + var e = document.createEvent('Event'); + e.initEvent(name, true, true); + obj.dispatchEvent(e); + } +};