Last active
May 29, 2019 05:32
-
-
Save seanpmaxwell/a7f1ca5f36dfa42a89f49609413c6b64 to your computer and use it in GitHub Desktop.
Revisions
-
seanpmaxwell revised this gist
May 29, 2019 . 1 changed file with 12 additions and 6 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,14 +1,17 @@ import { Logger } from '@overnightjs/logger'; import DemoServer from './DemoServer'; // Start the server or run tests if (process.env.NODE_ENV !== 'testing') { let server = new DemoServer(); server.start(process.env.NODE_ENV === 'development' ? 3001 : 8081); } else { const Jasmine = require('jasmine'); const jasmine = new Jasmine(); jasmine.loadConfig({ "spec_dir": "src", "spec_files": [ @@ -17,14 +20,17 @@ if (process.argv[2] !== 'test') { "stopSpecOnExpectationFailure": false, "random": true }); jasmine.onComplete((passed: boolean) => { if (passed) { Logger.Info('All tests have passed :)'); } else { Logger.Err('At least one test has failed :('); } }); let testPath = process.argv[3]; if (testPath) { testPath = `./src/${testPath}.test.ts`; jasmine.execute([testPath]); -
seanpmaxwell revised this gist
May 18, 2019 . 1 changed file with 0 additions and 9 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -2,18 +2,13 @@ import { cinfo, cerr } from 'simple-color-print'; import DemoServer from './DemoServer'; // Start the server or run tests if (process.argv[2] !== 'test') { let server = new DemoServer(); server.start(); } else { const Jasmine = require('jasmine'); const jasmine = new Jasmine(); jasmine.loadConfig({ "spec_dir": "src", "spec_files": [ @@ -22,18 +17,14 @@ if (process.argv[2] !== 'test') { "stopSpecOnExpectationFailure": false, "random": true }); jasmine.onComplete((passed: boolean) => { if (passed) { cinfo('All tests have passed :)'); } else { cerr('At least one test has failed :('); } }); let testPath = process.argv[3]; if (testPath) { testPath = `./src/${testPath}.test.ts`; jasmine.execute([testPath]); -
seanpmaxwell renamed this gist
Mar 3, 2019 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
seanpmaxwell revised this gist
Feb 14, 2019 . 1 changed file with 15 additions and 15 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,31 +1,29 @@ import { cinfo, cerr } from 'simple-color-print'; import DemoServer from './DemoServer'; // Start the server or run tests if (process.argv[2] !== 'test') { let server = new DemoServer(); server.start(); } else { const Jasmine = require('jasmine'); const jasmine = new Jasmine(); jasmine.loadConfig({ "spec_dir": "src", "spec_files": [ "./controllers/**/*.test.ts" ], "stopSpecOnExpectationFailure": false, "random": true }); jasmine.onComplete((passed: boolean) => { if (passed) { cinfo('All tests have passed :)'); @@ -34,9 +32,11 @@ if (process.argv[2] === 'dev') { } }); let testPath = process.argv[3]; if (testPath) { testPath = `./src/${testPath}.test.ts`; jasmine.execute([testPath]); } else { jasmine.execute(); } -
seanpmaxwell revised this gist
Feb 2, 2019 . 1 changed file with 2 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,3 +1,5 @@ import { cinfo, cerr } from 'simple-color-print' if (process.argv[2] === 'dev') { process.env.NODE_ENV = 'development'; -
seanpmaxwell created this gist
Jan 25, 2019 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,41 @@ if (process.argv[2] === 'dev') { process.env.NODE_ENV = 'development'; require('./src/DemoServer'); } else if (process.argv[2] === 'prod') { process.env.NODE_ENV = 'production'; } else if (process.argv[2] === 'test') { process.env.NODE_ENV = 'test'; const Jasmine = require('jasmine'); let jasmine = new Jasmine(); jasmine.loadConfig({ "spec_dir": "src", "spec_files": [ "./controllers/**/*.test.js" ], "stopSpecOnExpectationFailure": false, "random": true }); jasmine.onComplete(passed => { if (passed) { cinfo('All tests have passed :)'); } else { cerr('At least one test has failed :('); } }); if (process.argv[3]) { let test = `./src/${process.argv[3]}.test.js`; jasmine.execute([test], test); } else { jasmine.execute(); } }