~holger-seelig/cobweb.js/trunk

« back to all changes in this revision

Viewing changes to src/lib/jquery-contextMenu/test/integration/trigger-custom.js

  • Committer: Holger Seelig
  • Date: 2017-08-22 04:53:24 UTC
  • Revision ID: holger.seelig@yahoo.de-20170822045324-4of4xxgt79669gbt
Switched to npm.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
var pwd = process.cwd();
 
2
var helper = require('../integration_test_helper.js');
 
3
 
 
4
module.exports = {
 
5
  'Mouse hover opens context menu': function (test) {
 
6
    test
 
7
      .open('file://' + pwd + '/demo/trigger-custom.html')
 
8
      .click('#activate-menu')
 
9
      .waitForElement('#context-menu-layer')
 
10
      .assert.visible('.context-menu-root', 'Menu is present')
 
11
      .assert.exists('.context-menu-root', 'It opens context menu')
 
12
      .assert.numberOfElements('.context-menu-root li')
 
13
        .is(7, '7 context menu items are shown')
 
14
      .click('#context-menu-layer')
 
15
      .wait(100)
 
16
      .assert.doesntExist('#context-menu-layer', 'Click outside closes context menu')
 
17
      .done();
 
18
  }
 
19
};