Skip to content

Commit bcf7ae3

Browse files
author
Gabriel Cardona
committed
* Move mocha types dep to dev dependencies per this issue: #120
1 parent 561a164 commit bcf7ae3

3 files changed

Lines changed: 364 additions & 272 deletions

File tree

lib/Blockchain.ts

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,6 @@ export class Blockchain {
101101

102102
// Handle array of hashes.
103103
} else if (Array.isArray(hash)) {
104-
105104
// Dev note: must use axios.post for unit test stubbing.
106105
const response: AxiosResponse = await axios.post(
107106
`${this.restURL}blockchain/getBlockHeader`,
@@ -188,8 +187,6 @@ export class Blockchain {
188187
public async getMempoolEntry(
189188
txid: string | string[]
190189
): Promise<MempoolEntryResult> {
191-
//if (typeof txid !== "string") txid = JSON.stringify(txid)
192-
193190
try {
194191
if (typeof txid === "string") {
195192
const response: AxiosResponse = await axios.get(
@@ -275,7 +272,6 @@ export class Blockchain {
275272

276273
// Array of txids.
277274
} else if (Array.isArray(txids)) {
278-
279275
// Dev note: must use axios.post for unit test stubbing.
280276
const response: AxiosResponse = await axios.post(
281277
`${this.restURL}blockchain/getTxOutProof`,
@@ -348,7 +344,6 @@ export class Blockchain {
348344

349345
// Array of hashes.
350346
} else if (Array.isArray(proof)) {
351-
352347
// Dev note: must use axios.post for unit test stubbing.
353348
const response: AxiosResponse = await axios.post(
354349
`${this.restURL}blockchain/verifyTxOutProof`,

package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "bitbox-sdk",
3-
"version": "8.4.1",
3+
"version": "8.4.2",
44
"description": "BITBOX SDK for Bitcoin Cash",
55
"author": "Gabriel Cardona <gabriel@bitcoin.com>",
66
"contributors": [
@@ -10,7 +10,7 @@
1010
"test": "npm run test:unit",
1111
"test:no-build": "nyc mocha test/unit --timeout 60000 --exit",
1212
"test:unit": "tsc && nyc mocha test/unit --timeout 60000 --exit",
13-
"test:integration": "TEST=integration nyc --reporter=text mocha --timeout 30000 test/integration",
13+
"test:integration": "TEST=integration nyc --reporter=text mocha --timeout 30000 test/integration --exit",
1414
"test:integration:local": "TEST=integration SERVER=local nyc --reporter=text mocha --timeout 30000 test/integration --exit",
1515
"test:integration:stage": "TEST=integration SERVER=stage nyc --reporter=text mocha --timeout 30000 test/integration --exit",
1616
"coverage": "nyc report --reporter=text-lcov | coveralls",
@@ -33,11 +33,8 @@
3333
"dependencies": {
3434
"@types/bigi": "^1.4.2",
3535
"@types/bip39": "^2.4.2",
36-
"@types/chai": "^4.1.7",
37-
"@types/mocha": "^5.2.6",
3836
"@types/node": "^10.11.7",
3937
"@types/randombytes": "^2.0.0",
40-
"@types/sinon": "^7.0.11",
4138
"@types/wif": "^2.0.1",
4239
"assert": "^1.4.1",
4340
"axios": "0.19.0",
@@ -69,6 +66,9 @@
6966
},
7067
"devDependencies": {
7168
"@istanbuljs/nyc-config-typescript": "^0.1.3",
69+
"@types/chai": "^4.1.7",
70+
"@types/mocha": "^5.2.6",
71+
"@types/sinon": "^7.0.11",
7272
"chai": "^4.1.2",
7373
"coveralls": "^3.0.2",
7474
"eslint": "^5.5.0",

0 commit comments

Comments
 (0)