Skip to content

Commit d356d50

Browse files
committed
tns test init
1 parent 4d3beec commit d356d50

File tree

2 files changed

+19
-0
lines changed

2 files changed

+19
-0
lines changed

e2e/appTestNg/package.json

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
"@angular/router": "~8.2.0",
2323
"@nativescript/theme": "~2.2.0",
2424
"nativescript-angular": "~8.20.0",
25+
"nativescript-unit-test-runner": "^0.7.0",
2526
"reflect-metadata": "~0.1.12",
2627
"rxjs": "^6.4.0",
2728
"tns-core-modules": "~6.2.0",
@@ -30,6 +31,15 @@
3031
"devDependencies": {
3132
"@angular/compiler-cli": "~8.2.0",
3233
"@ngtools/webpack": "~8.2.0",
34+
"@types/karma-chai": "0.1.2",
35+
"@types/mocha": "5.2.7",
36+
"chai": "4.2.0",
37+
"karma": "4.4.1",
38+
"karma-chai": "0.1.0",
39+
"karma-mocha": "1.3.0",
40+
"karma-nativescript-launcher": "0.4.0",
41+
"karma-webpack": "3.0.5",
42+
"mocha": "6.2.2",
3343
"nativescript-dev-webpack": "~1.3.0",
3444
"typescript": "~3.5.3"
3545
},

e2e/appTestNg/src/tests/example.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
// A sample Mocha test
2+
describe('Array', function () {
3+
describe('#indexOf()', function () {
4+
it('should return -1 when the value is not present', function () {
5+
assert.equal(-1, [1, 2, 3].indexOf(5));
6+
assert.equal(-1, [1, 2, 3].indexOf(0));
7+
});
8+
});
9+
});

0 commit comments

Comments
 (0)