Skip to content

Commit 5a6657a

Browse files
committed
chore: Refactor the situation a bit for protractor. Can run locally now
1 parent 1f995c4 commit 5a6657a

File tree

5 files changed

+29
-118
lines changed

5 files changed

+29
-118
lines changed

e2e/_screenshot.js

Lines changed: 0 additions & 98 deletions
This file was deleted.

e2e/index.e2e.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
const screenshot = require('./_screenshot.js');
2-
31
describe('hello, protractor', function () {
42
describe('index', function () {
53
browser.get('/');

package.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
"tslint": "tslint -c tslint.json 'src/**/*.ts'",
1616
"typings": "typings install --ambient",
1717
"postinstall": "npm run typings",
18-
"e2e": "protractor ./protractor.conf.js",
18+
"e2e": "protractor test/protractor.conf.js",
1919
"inline-resources": "gulp inline-resources"
2020
},
2121
"version": "2.0.0-alpha.1",
@@ -27,8 +27,6 @@
2727
"angular2": "2.0.0-beta.12",
2828
"es6-promise": "^3.0.2",
2929
"es6-shim": "^0.35.0",
30-
"mapnik": "^3.5.2",
31-
"protractor": "^3.1.1",
3230
"reflect-metadata": "0.1.2",
3331
"rxjs": "5.0.0-beta.2",
3432
"systemjs": "0.19.4",
@@ -60,6 +58,7 @@
6058
"karma-firefox-launcher": "^0.1.7",
6159
"karma-jasmine": "^0.3.6",
6260
"karma-sauce-launcher": "^0.2.14",
61+
"protractor": "^3.1.1",
6362
"strip-ansi": "^3.0.0",
6463
"symlink-or-copy": "^1.0.1",
6564
"ts-node": "^0.5.5",

protractor.conf.js

Lines changed: 0 additions & 15 deletions
This file was deleted.

test/protractor.conf.js

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
/**
2+
* This file is Node ES6 and will not be translated to Dart.
3+
*/
4+
const path = require('path');
5+
6+
const E2E_BASE_URL = process.env['E2E_BASE_URL'] || 'http://localhost:4200';
7+
const config = {
8+
useAllAngular2AppRoots: true,
9+
specs: [ path.join(__dirname, '../e2e/**/*.e2e.js') ],
10+
baseUrl: E2E_BASE_URL
11+
};
12+
13+
14+
if (process.env['TRAVIS'] !== undefined) {
15+
const key = require('../scripts/sauce/sauce_config');
16+
config.sauceUser = process.env['SAUCE_USERNAME'];
17+
config.sauceKey = key;
18+
config.capabilities = {
19+
'browserName': 'chrome',
20+
'tunnel-identifier': process.env['TRAVIS_JOB_NUMBER'],
21+
'build': process.env['TRAVIS_JOB_NUMBER'],
22+
'name': 'Material 2 E2E Tests'
23+
};
24+
}
25+
26+
27+
exports.config = config;

0 commit comments

Comments
 (0)