Skip to content

Instantly share code, notes, and snippets.

@alduro
Last active January 3, 2016 09:39
Show Gist options
  • Save alduro/8443874 to your computer and use it in GitHub Desktop.
Save alduro/8443874 to your computer and use it in GitHub Desktop.
// Karma configuration
// Generated on Wed Jan 15 2014 15:09:26 GMT-0300 (ART)
module.exports = function(config) {
config.set({
// base path, that will be used to resolve files and exclude
basePath: '.',
// frameworks to use
frameworks: ['ng-scenario'],
// list of files / patterns to load in the browser
files: [
//3rd Party Code
//App-specific Code
'../public/app/scripts/lib/router.js',
'../public/app/scripts/config/config.js',
'../public/app/scripts/services/**/*.js',
'../public/app/scripts/directives/**/*.js',
'../public/app/scripts/controllers/**/*.js',
'../public/app/scripts/filters/**/*.js',
'../public/app/scripts/config/routes.js',
'../public/app/scripts/main.js',
'lib/components/angular/angular.js',
'lib/components/angular-mocks/angular-mocks.js',
'lib/components/angular-scenario/angular-scenario.js',
'lib/components/angular-route/angular-route.js',
'lib/components/angularjs-scope.safeapply/src/Scope.SafeApply.js',
'e2e/**/*.js'
],
// list of files to exclude
exclude: [
],
// test results reporter to use
// possible values: 'dots', 'progress', 'junit', 'growl', 'coverage'
reporters: ['progress'],
// web server port
port: 9876,
// enable / disable colors in the output (reporters and logs)
colors: true,
// level of logging
// possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
logLevel: config.LOG_INFO,
// enable / disable watching file and executing tests whenever any file changes
autoWatch: true,
// Start these browsers, currently available:
// - Chrome
// - ChromeCanary
// - Firefox
// - Opera (has to be installed with `npm install karma-opera-launcher`)
// - Safari (only Mac; has to be installed with `npm install karma-safari-launcher`)
// - PhantomJS
// - IE (only Windows; has to be installed with `npm install karma-ie-launcher`)
browsers: ['Chrome'],
// If browser does not capture in given timeout [ms], kill it
captureTimeout: 60000,
// Continuous Integration mode
// if true, it capture browsers, run tests and exit
singleRun: false
});
};
Error:
Running "karma:e2e" (karma) task
WARN [karma]: Port 9876 in use
INFO [karma]: Karma v0.10.6 server started at http://localhost:9877/
INFO [launcher]: Starting browser Chrome
INFO [Chrome 32.0.1700 (Mac OS X 10.9.1)]: Connected on socket QwPIjKCBoeDhZ1KPhA3j
Chrome 32.0.1700 (Mac OS X 10.9.1) ERROR
Uncaught ReferenceError: module is not defined
at /Users/aldo/Satio/Desarrollo/node/control/test/e2e/login.js:12
Chrome 32.0.1700 (Mac OS X 10.9.1): Executed 0 of 0 ERROR (2.102 secs / 0 secs)
Warning: Task "karma:e2e" failed. Used --force, continuing.
Done, but with warnings.
bower.json
{
"name": "control",
"version": "1.0.0",
"homepage": "https://github.com/redwolfsecurity/control",
"authors": [
"Aldo Nievas <aldo@satio.com.ar>"
],
"license": "MIT",
"dependencies": {
"angular": "1.2.8",
"angular-route": "1.2.8",
"angular-mocks": "1.2.8",
"angularjs-scope.safeapply": "*",
"angular-scenario": "~1.2.8"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment