From 07fcbe5890d4ef1b63ba4f6e131162d62a18fb52 Mon Sep 17 00:00:00 2001
From: Daniel Cousens <github@dcousens.com>
Date: Thu, 13 Sep 2018 17:34:42 +1000
Subject: [PATCH 1/2] rm unused imports

---
 test/transaction_builder.js | 2 --
 1 file changed, 2 deletions(-)

diff --git a/test/transaction_builder.js b/test/transaction_builder.js
index 88294fb..5a6b86f 100644
--- a/test/transaction_builder.js
+++ b/test/transaction_builder.js
@@ -4,8 +4,6 @@ const assert = require('assert')
 const baddress = require('../src/address')
 const bcrypto = require('../src/crypto')
 const bscript = require('../src/script')
-const ops = require('bitcoin-ops')
-const payments = require('../src/payments')
 
 const ECPair = require('../src/ecpair')
 const Transaction = require('../src/transaction')

From 1c64094c2949747cb7ae4434d4a163611b7ef35e Mon Sep 17 00:00:00 2001
From: Daniel Cousens <github@dcousens.com>
Date: Thu, 13 Sep 2018 17:34:50 +1000
Subject: [PATCH 2/2] use hoodwink@2.0.0

---
 package.json   |  2 +-
 test/ecpair.js | 10 +++++-----
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/package.json b/package.json
index a696033..6d6b524 100644
--- a/package.json
+++ b/package.json
@@ -53,7 +53,7 @@
     "bn.js": "^4.11.8",
     "bs58": "^4.0.0",
     "dhttp": "^2.5.0",
-    "hoodwink": "^1.0.0",
+    "hoodwink": "^2.0.0",
     "minimaldata": "^1.0.2",
     "mocha": "^5.2.0",
     "nyc": "^11.8.0",
diff --git a/test/ecpair.js b/test/ecpair.js
index 8a246f1..78223ca 100644
--- a/test/ecpair.js
+++ b/test/ecpair.js
@@ -187,8 +187,8 @@ describe('ECPair', function () {
     })
 
     it('loops until d is within interval [1, n) : 1', hoodwink(function () {
-      const rng = this.stub(function f () {
-        if (f.calls === 0) return ZERO // 0
+      const rng = this.stub(function () {
+        if (rng.calls === 0) return ZERO // 0
         return ONE // >0
       }, 2)
 
@@ -196,9 +196,9 @@ describe('ECPair', function () {
     }))
 
     it('loops until d is within interval [1, n) : n - 1', hoodwink(function () {
-      const rng = this.stub(function f () {
-        if (f.calls === 0) return ZERO // <1
-        if (f.calls === 1) return GROUP_ORDER // >n-1
+      const rng = this.stub(function () {
+        if (rng.calls === 0) return ZERO // <1
+        if (rng.calls === 1) return GROUP_ORDER // >n-1
         return GROUP_ORDER_LESS_1 // n-1
       }, 3)