So I've tried to use completed-tutorial branch with intern-geezer since I'm using phantomJS (followed these instructions) but I'm getting error.
It seems that this.remote.get(require.toUrl('index.html')) .... from tests/functional/index.js is not resolving to the proper url for phantomjs.
Any ideas?
console output:
intern-tutorial-geezer git:(completed-tutorial) ✗ node node_modules/intern-geezer/runner.js config=tests/intern
Defaulting to "runner" reporter
Listening on 0.0.0.0:9000
Initialised phantomjs 1.9.1 on linux-unknown-32bit
Test main - index - greeting form FAILED on phantomjs 1.9.1 on linux-unknown-32bit:
Error: Cannot call method 'get' of undefined
TypeError: Cannot call method 'get' of undefined
at registerSuite.greeting form [as test] (/var/www/intern-tutorial-geezer/tests/functional/index.js:11:6)
at declare.run (/var/www/intern-tutorial-geezer/node_modules/intern-geezer/lib/Test.js:151:19)
at /var/www/intern-tutorial-geezer/node_modules/intern-geezer/lib/Suite.js:158:13
at signalListener (/var/www/intern-tutorial-geezer/node_modules/intern-geezer/node_modules/dojo/Deferred.js:37:21)
at Promise.then.promise.then (/var/www/intern-tutorial-geezer/node_modules/intern-geezer/node_modules/dojo/Deferred.js:258:5)
at /var/www/intern-tutorial-geezer/node_modules/intern-geezer/lib/Suite.js:157:26
at process._tickCallback (node.js:415:13)
=============================== Coverage summary ===============================
Statements : 100% ( 4/4 )
Branches : 100% ( 2/2 )
Functions : 100% ( 2/2 )
Lines : 100% ( 4/4 )
================================================================================
phantomjs 1.9.1 on linux-unknown-32bit: 1/3 tests failed
=============================== Coverage summary ===============================
Statements : 100% ( 4/4 )
Branches : 100% ( 2/2 )
Functions : 100% ( 2/2 )
Lines : 100% ( 4/4 )
================================================================================
intern.js
// Learn more about configuring this file at <https://github.com/theintern/intern/wiki/Configuring-Intern>.
// These default settings work OK for most people. The options that *must* be changed below are the
// packages, suites, excludeInstrumentation, and (if you want functional tests) functionalSuites.
define({
// The port on which the instrumenting proxy will listen
proxyPort: 9000,
// A fully qualified URL to the Intern proxy
proxyUrl: 'http://localhost:9000/',
// Default desired capabilities for all environments. Individual capabilities can be overridden by any of the
// specified browser environments in the `environments` array below as well. See
// https://code.google.com/p/selenium/wiki/DesiredCapabilities for standard Selenium capabilities and
// https://saucelabs.com/docs/additional-config#desired-capabilities for Sauce Labs capabilities.
// Note that the `build` capability will be filled in with the current commit ID from the Travis CI environment
// automatically
capabilities: {
'selenium-version': '2.30.0'
},
// Browsers to run integration testing against. Note that version numbers must be strings if used with Sauce
// OnDemand. Options that will be permutated are browserName, version, platform, and platformVersion; any other
// capabilities options specified for an environment will be copied as-is
environments: [
{ browserName: 'phantom' }
],
// Maximum number of simultaneous integration tests that should be executed on the remote WebDriver service
maxConcurrency: 3,
// Whether or not to start Sauce Connect before running tests
useSauceConnect: false,
// Connection information for the remote WebDriver service. If using Sauce Labs, keep your username and password
// in the SAUCE_USERNAME and SAUCE_ACCESS_KEY environment variables unless you are sure you will NEVER be
// publishing this configuration file somewhere
webdriver: {
host: 'localhost',
port: 4444
},
// Configuration options for the module loader; any AMD configuration options supported by the Dojo loader can be
// used here
loader: {
// Packages that should be registered with the loader in each testing environment
packages: [ { name: 'app', location: 'app' } ]
},
// Non-functional test suite(s) to run in each browser
suites: [ 'tests/hello' ],
// Functional test suite(s) to run in each browser once non-functional tests are completed
functionalSuites: [ 'tests/functional/index' ],
// A regular expression matching URLs to files that should not be included in code coverage analysis
excludeInstrumentation: /^tests\//
});
You’ll need to use this.get('remote') not this.remote in the geezer branch, because old IE doesn’t support ES5 getter/setters. This needs to be clearer in the documentation.
So I've tried to use completed-tutorial branch with intern-geezer since I'm using phantomJS (followed these instructions) but I'm getting error.
It seems that
this.remote.get(require.toUrl('index.html')) ....
fromtests/functional/index.js
is not resolving to the proper url for phantomjs.Any ideas?
console output:
intern.js