From 5477eb2bb416deda3cf2fe7ba1cb29ffdd53128d Mon Sep 17 00:00:00 2001 From: Mike Pugh Date: Thu, 8 Feb 2018 09:19:57 -0500 Subject: [PATCH] Update tests involving getAccountInfoStub --- lib/plugins/aws/deployFunction/index.test.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/plugins/aws/deployFunction/index.test.js b/lib/plugins/aws/deployFunction/index.test.js index a1c28f0ae..3a2bf1858 100644 --- a/lib/plugins/aws/deployFunction/index.test.js +++ b/lib/plugins/aws/deployFunction/index.test.js @@ -1,5 +1,5 @@ 'use strict'; - +/* eslint-disable no-unused-expressions */ const chai = require('chai'); const sinon = require('sinon'); const path = require('path'); @@ -153,7 +153,7 @@ describe('AwsDeployFunction', () => { const arn = 'arn:aws:iam::123456789012:role/role'; return awsDeployFunction.normalizeArnRole(arn).then((result) => { - expect(getAccountInfoStub.calledOnce).to.be.equal(false); + expect(getAccountInfoStub).to.not.have.been.called; expect(result).to.be.equal(arn); }); }); @@ -162,7 +162,7 @@ describe('AwsDeployFunction', () => { const roleName = 'MyCustomRole'; return awsDeployFunction.normalizeArnRole(roleName).then((result) => { - expect(getAccountInfoStub.calledOnce).to.be.equal(true); + expect(getAccountInfoStub).to.have.been.called; expect(result).to.be.equal('arn:aws:iam::123456789012:role/role_123'); }); }); @@ -177,7 +177,7 @@ describe('AwsDeployFunction', () => { return awsDeployFunction.normalizeArnRole(roleObj).then((result) => { expect(getRoleStub.calledOnce).to.be.equal(true); - expect(getAccountInfoStub.calledOnce).to.be.equal(false); + expect(getAccountInfoStub).to.not.have.been.called; expect(result).to.be.equal('arn:aws:iam::123456789012:role/role_2'); }); });