Skip to content

Instantly share code, notes, and snippets.

View jason0x43's full-sized avatar

Jason Cheatham jason0x43

View GitHub Profile
@jason0x43
jason0x43 / file.js
Last active May 11, 2016 02:47
Intern execute test
// tests/intern.js
define({
environments: [ { browserName: 'chrome' } ],
tunnel: 'NullTunnel',
functionalSuites: [ 'tests/functional' ],
excludeInstrumentation: /^(?:tests|node_modules)\//
});
// tests/functional.js
define([
@jason0x43
jason0x43 / intern_cjs.js
Last active August 29, 2015 14:18
Writing CommonJS tests with Intern
// tests/cjs.js -- AMD module to load CJS tests
define(function (require) {
var registerSuite = require('intern!object');
var testLoader = require('dojo/node!./cjs/all');
testLoader(registerSuite);
});
// tests/cjs/all.js -- CJS module that loads individual CJS test suites
module.exports = function (registerSuite) {
require('./unit.js')(registerSuite);