Skip to content

Commit f487e8f

Browse files
authored
updated tests for es2015 (#275)
1 parent 0dfa672 commit f487e8f

4 files changed

Lines changed: 26 additions & 4 deletions

File tree

package.json

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,12 @@
33
"version": "1.2.2",
44
"scripts": {
55
"lint": "tslint **/*.ts --exclude \"**/*.d.ts\" -t verbose --project tsconfig.lib.json",
6-
"test": "ng test angular-cld",
7-
"test-headless": "ng test angular-cld --browsers ChromeHeadless",
6+
"test": "npm run test-es5 && npm run test-es2015",
7+
"test-es5": "ng test angular-cld --tsConfig=projects/angular-cld/tsconfig-es5.spec.json",
8+
"test-es2015": "ng test angular-cld --tsConfig=projects/angular-cld/tsconfig-es2015.spec.json",
9+
"test-headless": "npm run test-es5-headless && npm run test-es2015-headless",
10+
"test-es5-headless": "ng test angular-cld --tsConfig=projects/angular-cld/tsconfig-es5.spec.json --browsers ChromeHeadless",
11+
"test-es2015-headless": "ng test angular-cld --tsConfig=projects/angular-cld/tsconfig-es2015.spec.json --browsers ChromeHeadless",
812
"install-sample-from-source": "node ./scripts/install-sample-from-source.js samples/photo_album",
913
"install-sample-from-source:jquery": "node ./scripts/install-sample-from-source.js samples/photo_album_with_jquery",
1014
"build": "ng build angular-cld && npm run copy-lib-assets",
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"extends": "../../tsconfig.json",
3+
"compilerOptions": {
4+
"outDir": "../../out-tsc/spec",
5+
"types": [
6+
"jasmine",
7+
"node"
8+
],
9+
"target": "es2015"
10+
},
11+
"files": [
12+
"src/test.ts"
13+
],
14+
"include": [
15+
"**/*.spec.ts",
16+
"**/*.d.ts"
17+
]
18+
}

projects/angular-cld/tsconfig.spec.json renamed to projects/angular-cld/tsconfig-es5.spec.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@
55
"types": [
66
"jasmine",
77
"node"
8-
]
8+
],
9+
"target": "es5"
910
},
1011
"files": [
1112
"src/test.ts"

tsconfig.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
"moduleResolution": "node",
99
"emitDecoratorMetadata": true,
1010
"experimentalDecorators": true,
11-
"target": "es5",
1211
"typeRoots": [
1312
"node_modules/@types"
1413
],

0 commit comments

Comments
 (0)