1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00

Update sinion methods. sandbox.create() -> createSandbox()

This commit is contained in:
Thomas 2018-04-04 12:48:30 -07:00
parent ae4f3366bf
commit 06e25205b2
7 changed files with 7 additions and 7 deletions

View File

@ -9,7 +9,7 @@ var reducers = require(path.join(__dirname, '..', '..', '..', 'ui', 'app', 'redu
describe('tx confirmation screen', function () { describe('tx confirmation screen', function () {
beforeEach(function () { beforeEach(function () {
this.sinon = sinon.sandbox.create() this.sinon = sinon.createSandbox()
}) })
afterEach(function () { afterEach(function () {

View File

@ -8,7 +8,7 @@ describe('infura-controller', function () {
before(async function () { before(async function () {
infuraController = new InfuraController() infuraController = new InfuraController()
sandbox = sinon.sandbox.create() sandbox = sinon.createSandbox()
sinon.stub(infuraController, 'checkInfuraNetworkStatus').resolves(response) sinon.stub(infuraController, 'checkInfuraNetworkStatus').resolves(response)
networkStatus = await infuraController.checkInfuraNetworkStatus() networkStatus = await infuraController.checkInfuraNetworkStatus()
}) })

View File

@ -8,7 +8,7 @@ const firstTimeState = require('../../app/scripts/first-time-state')
describe('MetaMaskController', function () { describe('MetaMaskController', function () {
let metamaskController let metamaskController
const sandbox = sinon.sandbox.create() const sandbox = sinon.createSandbox()
const noop = () => {} const noop = () => {}
beforeEach(function () { beforeEach(function () {

View File

@ -6,7 +6,7 @@ var contractNamer = require(path.join(__dirname, '..', '..', 'old-ui', 'lib', 'c
describe('contractNamer', function () { describe('contractNamer', function () {
beforeEach(function () { beforeEach(function () {
this.sinon = sinon.sandbox.create() this.sinon = sinon.createSandbox()
}) })
afterEach(function () { afterEach(function () {

View File

@ -294,7 +294,7 @@ describe('PendingTransactionTracker', function () {
}) })
afterEach(() => { afterEach(() => {
pendingTxTracker.publishTransaction.reset() pendingTxTracker.publishTransaction.restore()
}) })
it('should publish the transaction', function (done) { it('should publish the transaction', function (done) {

View File

@ -10,7 +10,7 @@ var reducers = require(path.join(__dirname, '..', '..', '..', 'ui', 'app', 'redu
describe('#unlockMetamask(selectedAccount)', function () { describe('#unlockMetamask(selectedAccount)', function () {
beforeEach(function () { beforeEach(function () {
// sinon allows stubbing methods that are easily verified // sinon allows stubbing methods that are easily verified
this.sinon = sinon.sandbox.create() this.sinon = sinon.createSandbox()
}) })
afterEach(function () { afterEach(function () {

View File

@ -10,7 +10,7 @@ describe('util', function () {
for (var i = 0; i < 18; i++) { ethInWei += '0' } for (var i = 0; i < 18; i++) { ethInWei += '0' }
beforeEach(function () { beforeEach(function () {
this.sinon = sinon.sandbox.create() this.sinon = sinon.createSandbox()
}) })
afterEach(function () { afterEach(function () {