Skip to content

Instantly share code, notes, and snippets.

@thomastuts
Created October 24, 2014 15:41
Show Gist options
  • Select an option

  • Save thomastuts/6bdcbb2f4dc71c9d5312 to your computer and use it in GitHub Desktop.

Select an option

Save thomastuts/6bdcbb2f4dc71c9d5312 to your computer and use it in GitHub Desktop.

Revisions

  1. Thomas Tuts created this gist Oct 24, 2014.
    27 changes: 27 additions & 0 deletions gistfile1.js
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,27 @@
    var gulp = require('gulp');
    var open = require('gulp-open');
    var karma = require('karma').server;
    var protractor = require('gulp-protractor').protractor;
    var paths = require('./paths');

    module.exports = {
    unit: function (done) {
    karma.start({
    configFile: paths.tests.unit.config,
    singleRun: true
    }, done);
    },
    unitCoverage: function () {
    gulp.src('test/coverage/index.html')
    .pipe(open("<%file.path%>"));
    },
    e2e: function () {
    return gulp.src(paths.tests.e2e.testFiles)
    .pipe(protractor({
    configFile: paths.tests.e2e.config
    }))
    .on('error', function (e) {
    throw e;
    });
    }
    };