aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFabio Berger <me@fabioberger.com>2017-05-24 20:28:35 +0800
committerGitHub <noreply@github.com>2017-05-24 20:28:35 +0800
commitd6b9bb2d736eceb4e927d4d6f26ac7cbed77dbd6 (patch)
tree7572732c9ac8c23c715f21f6bb6b31066e61395c
parentcc4ff03bb326ddd76a736a63fcf5662545af0846 (diff)
parent2067e16e14248c182577c942673d3f0546ce4a17 (diff)
downloaddexon-sol-tools-d6b9bb2d736eceb4e927d4d6f26ac7cbed77dbd6.tar
dexon-sol-tools-d6b9bb2d736eceb4e927d4d6f26ac7cbed77dbd6.tar.gz
dexon-sol-tools-d6b9bb2d736eceb4e927d4d6f26ac7cbed77dbd6.tar.bz2
dexon-sol-tools-d6b9bb2d736eceb4e927d4d6f26ac7cbed77dbd6.tar.lz
dexon-sol-tools-d6b9bb2d736eceb4e927d4d6f26ac7cbed77dbd6.tar.xz
dexon-sol-tools-d6b9bb2d736eceb4e927d4d6f26ac7cbed77dbd6.tar.zst
dexon-sol-tools-d6b9bb2d736eceb4e927d4d6f26ac7cbed77dbd6.zip
Merge pull request #5 from 0xProject/tests
Tests
-rw-r--r--package.json9
-rw-r--r--test/0x.js.ts12
-rw-r--r--tsconfig.json3
3 files changed, 21 insertions, 3 deletions
diff --git a/package.json b/package.json
index c395340eb..8540e7785 100644
--- a/package.json
+++ b/package.json
@@ -15,7 +15,8 @@
"build:commonjs": "tsc",
"build:es6": "tsc -m es6 --outDir lib-esm",
"build": "npm run clean && run-p build:*",
- "lint": "tslint src/ts/**/*"
+ "lint": "tslint src/ts/**/*",
+ "test": "run-s clean build:commonjs && mocha lib/test/**/*.js"
},
"repository": {
"type": "git",
@@ -26,7 +27,11 @@
"node": ">=6.0.0"
},
"devDependencies": {
+ "@types/chai": "^3.5.2",
+ "@types/mocha": "^2.2.41",
"awesome-typescript-loader": "^3.1.3",
+ "chai": "^3.5.0",
+ "mocha": "^3.4.1",
"npm-run-all": "^4.0.2",
"shx": "^0.2.2",
"tslint": "^5.3.2",
@@ -34,4 +39,4 @@
"typescript": "^2.3.3",
"webpack": "^2.6.0"
}
-}
+} \ No newline at end of file
diff --git a/test/0x.js.ts b/test/0x.js.ts
new file mode 100644
index 000000000..65475bf32
--- /dev/null
+++ b/test/0x.js.ts
@@ -0,0 +1,12 @@
+import {ZeroEx} from '../src/ts/0x.js';
+import {expect} from 'chai';
+import 'mocha';
+
+describe('ZeroEx library', () => {
+ describe('#verifySignature', () => {
+ it('should return undefined', () => {
+ const zeroEx = new ZeroEx();
+ expect(zeroEx.verifySignature()).to.be.undefined;
+ });
+ });
+});
diff --git a/tsconfig.json b/tsconfig.json
index 5ba086da6..1c3f8eb0a 100644
--- a/tsconfig.json
+++ b/tsconfig.json
@@ -10,6 +10,7 @@
"strictNullChecks": true
},
"include": [
- "./src/ts/**/*"
+ "./src/**/*",
+ "./test/**/*"
]
}