Skip to content

Commit

Permalink
chore(npm-scripts): ensure they work on Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
petebacondarwin committed Mar 27, 2014
1 parent 5d2baf8 commit 52187e2
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 28 deletions.
9 changes: 3 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,9 @@ node_js:
before_script:
- export DISPLAY=:99.0
- sh -e /etc/init.d/xvfb start
- npm install --quiet -g karma
- npm install --quiet -g protractor
- ./scripts/web-server.js > /dev/null &
- npm start
- sleep 1 # give server time to start

script:
- karma start config/karma.conf.js --no-auto-watch --single-run --reporters=dots --browsers=Firefox
- webdriver-manager update
- protractor config/protractor-conf.js --browser=firefox
- node_modules/.bin/karma start test/karma.conf.js --no-auto-watch --single-run --reporters=dots --browsers=Firefox
- node_modules/.bin/protractor test/protractor-conf.js --browser=firefox
6 changes: 3 additions & 3 deletions app/index-async.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,17 @@
</style>
<script>
// include angular loader, which allows the files to load in any order

/*
/*
AngularJS v1.2.15
(c) 2010-2014 Google, Inc. http://angularjs.org
License: MIT
*/
(function(){'use strict';function d(a){return function(){var c=arguments[0],b,c="["+(a?a+":":"")+c+"] http://errors.angularjs.org/1.2.15/"+(a?a+"/":"")+c;for(b=1;b<arguments.length;b++)c=c+(1==b?"?":"&")+"p"+(b-1)+"="+encodeURIComponent("function"==typeof arguments[b]?arguments[b].toString().replace(/ \{[\s\S]*$/,""):"undefined"==typeof arguments[b]?"undefined":"string"!=typeof arguments[b]?JSON.stringify(arguments[b]):arguments[b]);return Error(c)}}(function(a){var c=d("$injector"),b=d("ng");a=a.angular||
(a.angular={});a.$$minErr=a.$$minErr||d;return a.module||(a.module=function(){var a={};return function(e,d,f){if("hasOwnProperty"===e)throw b("badname","module");d&&a.hasOwnProperty(e)&&(a[e]=null);return a[e]||(a[e]=function(){function a(c,d,e){return function(){b[e||"push"]([c,d,arguments]);return g}}if(!d)throw c("nomod",e);var b=[],h=[],k=a("$injector","invoke"),g={_invokeQueue:b,_runBlocks:h,requires:d,name:e,provider:a("$provide","provider"),factory:a("$provide","factory"),service:a("$provide",
(a.angular={});a.$minErr=a.$minErr||d;return a.module||(a.module=function(){var a={};return function(e,d,f){if("hasOwnProperty"===e)throw b("badname","module");d&&a.hasOwnProperty(e)&&(a[e]=null);return a[e]||(a[e]=function(){function a(c,d,e){return function(){b[e||"push"]([c,d,arguments]);return g}}if(!d)throw c("nomod",e);var b=[],h=[],k=a("$injector","invoke"),g={_invokeQueue:b,_runBlocks:h,requires:d,name:e,provider:a("$provide","provider"),factory:a("$provide","factory"),service:a("$provide",
"service"),value:a("$provide","value"),constant:a("$provide","constant","unshift"),animation:a("$animateProvider","register"),filter:a("$filterProvider","register"),controller:a("$controllerProvider","register"),directive:a("$compileProvider","directive"),config:k,run:function(a){h.push(a);return this}};f&&k(f);return g}())}}())})(window)})(window);
//# sourceMappingURL=angular-loader.min.js.map


// include a third-party async loader library
/*!
* $script.js v1.3
Expand Down
7 changes: 0 additions & 7 deletions bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,6 @@
"homepage": "https://github.com/angular/angular-seed",
"license": "MIT",
"private": true,
"ignore": [
"**/.*",
"node_modules",
"bower_components",
"test",
"tests"
],
"dependencies": {
"angular": "1.2.x",
"angular-route": "1.2.x",
Expand Down
Empty file removed logs/.gitkeep
Empty file.
22 changes: 11 additions & 11 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,23 +6,23 @@
"repository": "https://github.com/angular/angular-seed",
"license": "MIT",
"devDependencies": {
"phantomjs": "~1.9",
"karma": "~0.10",
"karma-junit-reporter": "~0.1",
"karma-jasmine": "~0.1",
"protractor": "~0.17.0",
"http-server": "^0.6.1",
"bower": "^1.3.1"
"bower": "^1.3.1",
"shelljs": "^0.2.6"
},
"scripts": {
"postinstall": "node node_modules/.bin/bower install; sed '/@@NG_LOADER@@/{\ns/@@NG_LOADER@@//g\nr bower_components/angular-loader/angular-loader.min.js\n}' app/index-async.html.template > app/index-async.html",
"postinstall": "bower install",
"postupdate": "bower update",

"prestart": "npm install",
"start": "node node_modules/.bin/http-server",
"start": "http-server -p 8000",
"test": "karma start test/karma.conf.js --single-run",

"pretest": "npm install",
"test": "node node_modules/.bin/karma start config/karma.conf.js",

"protractor": "npm install; node node_modules/.bin/webdriver-manager update; node node_modules/.bin/protractor config/protractor-conf.js"
"update-webdriver": "webdriver-manager update",
"protractor": "protractor test/protractor-conf.js",
"test-watch": "karma start test/karma.conf.js",

"update-index-async": "node -e \"require('shelljs/global'); sed('@@NG_LOADER@@', cat('bower_components/angular-loader/angular-loader.min.js'), 'app/index-async.html.template').to('app/index-async.html');\""
}
}
2 changes: 1 addition & 1 deletion test/protractor-conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ exports.config = {
'browserName': 'chrome'
},

baseUrl: 'http://localhost:8080/app/',
baseUrl: 'http://localhost:8000/app/',

framework: 'jasmine',

Expand Down

0 comments on commit 52187e2

Please sign in to comment.