Permalink
Browse files

Remove gulp and add npm scripts

  • Loading branch information...
1 parent a0b5b94 commit cc203653baf4c83153bcc8b72798c2610bb5ca2d @atoakley atoakley committed Sep 6, 2017
View
@@ -9,6 +9,7 @@
"sourceType": "module"
},
"rules": {
+ "no-unused-vars": "warn",
"indent": [
"error",
4
View
13 .nycrc
@@ -0,0 +1,13 @@
+{
+ "check-coverage": false,
+ "per-file": true,
+ "produce-source-map": true,
+ "include": [
+ "src/**/*.js"
+ ],
+ "reporter": [
+ "lcov",
+ "text"
+ ],
+ "temp-directory": "coverage/.nyc_output"
+}
View
@@ -7,76 +7,31 @@
{
"type": "node",
"request": "launch",
- "name": "Run Unit Tests",
- "program": "${workspaceRoot}/node_modules/gulp/bin/gulp.js",
- "stopOnEntry": false,
- "args": [
- "run-tests"
+ "name": "Debug unit tests",
+ "runtimeExecutable": "${workspaceRoot}/node_modules/.bin/cross-env",
+ "runtimeArgs": [
+ "RUN_TRANSFORM=true",
+ "node",
+ "--nolazy",
+ "--debug-brk=5858",
+ "${workspaceRoot}/node_modules/jasmine/bin/jasmine.js",
+ "--config=${workspaceRoot}/jasmine.json"
],
- "protocol": "inspector",
"console": "integratedTerminal",
- "cwd": "${workspaceRoot}"
- },
- {
- "type": "node",
- "request": "launch",
- "name": "Run Merge and Validate Unit Tests with Coverage",
- "program": "${workspaceRoot}/node_modules/gulp/bin/gulp.js",
- "stopOnEntry": false,
- "env": {
- "RUN_TRANSFORM": "false"
- },
- "args": [
- "run-tests-with-coverage"
- ],
- "protocol": "inspector",
- "console": "integratedTerminal",
- "cwd": "${workspaceRoot}"
- },
- {
- "type": "node",
- "request": "launch",
- "name": "Run All Unit Tests with Coverage",
- "program": "${workspaceRoot}/node_modules/gulp/bin/gulp.js",
- "stopOnEntry": false,
- "env": {
- "RUN_TRANSFORM": "true"
- },
- "args": [
- "run-tests-with-coverage"
- ],
- "protocol": "inspector",
- "console": "integratedTerminal",
- "cwd": "${workspaceRoot}"
+ "protocol": "legacy",
+ "port": 5858
},
{
"type": "node",
"request": "launch",
- "name": "Run ESLint",
- "program": "${workspaceRoot}/node_modules/gulp/bin/gulp.js",
- "stopOnEntry": false,
- "args": [
- "run-eslint"
+ "name": "Run eslint",
+ "runtimeExecutable": "${workspaceRoot}/node_modules/.bin/eslint",
+ "runtimeArgs": [
+ "--config", ".eslintrc.json",
+ "src/**/*.js",
+ "test/**/*.js"
],
- "protocol": "inspector",
- "console": "integratedTerminal",
- "cwd": "${workspaceRoot}"
- },
- {
- "type": "node",
- "request": "launch",
- "name": "Launch Program",
- "program": "${workspaceRoot}/app.js",
- "cwd": "${workspaceRoot}"
- },
- {
- "type": "node",
- "request": "launch",
- "name": "Launch Command Line",
- "program": "${workspaceRoot}/index.js",
- "cwd": "${workspaceRoot}",
- "args": [
- ]
+ "console": "integratedTerminal"
},
{
"type": "node",
View
@@ -1,39 +0,0 @@
-'use strict';
-
-let gulp = require('gulp');
-let jasmine = require('gulp-jasmine');
-let istanbul = require('gulp-istanbul');
-let eslint = require('gulp-eslint');
-
-gulp.task('pre-test', () =>{
- return gulp.src(['src/core/**/*.js'])
- .pipe(istanbul())
- .pipe(istanbul.hookRequire());
-});
-
-// Run tests
-gulp.task('run-tests-with-coverage', ['pre-test'], () => {
- global.testConfiguration = {
- runTransform : (process.env.RUN_TRANSFORM) ? (process.env.RUN_TRANSFORM === 'true') : true
- };
-
- return gulp.src('test/**/*.js')
- .pipe(jasmine())
- .pipe(istanbul.writeReports());
-});
-
-gulp.task('run-tests', () => {
- global.testConfiguration = {
- runTransform : true
- };
-
- return gulp.src('test/**/*.js')
- .pipe(jasmine());
-});
-
-gulp.task('run-eslint', () => {
- return gulp.src(['src/**/*.js', 'test/**/*.js'])
- .pipe(eslint())
- .pipe(eslint.format())
- .pipe(eslint.failAfterError());
-});
@@ -1,5 +1,5 @@
{
- "spec_dir": "spec",
+ "spec_dir": "test",
"spec_files": [
"**/*[sS]pec.js"
],
Oops, something went wrong.

0 comments on commit cc20365

Please sign in to comment.