From 8143fa3ab3ccd9b61b4a556a6555023a880de502 Mon Sep 17 00:00:00 2001 From: Juan Cruz Viotti Date: Fri, 14 Nov 2014 15:34:14 -0400 Subject: [PATCH] Update tests that assume saveToken returned the token as the second parameter --- lib/cli-modules/auth/auth.spec.coffee | 6 ++---- lib/token/token.spec.coffee | 2 +- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/lib/cli-modules/auth/auth.spec.coffee b/lib/cli-modules/auth/auth.spec.coffee index 173a5fa9..de12400f 100644 --- a/lib/cli-modules/auth/auth.spec.coffee +++ b/lib/cli-modules/auth/auth.spec.coffee @@ -37,8 +37,7 @@ describe 'Auth:', -> expect(isLoggedIn).to.be.false auth.login(johnDoeFixture.credentials, callback) - (authToken, callback) -> - expect(authToken).to.be.a.string + (callback) -> auth.isLoggedIn (isLoggedIn) -> return callback(null, isLoggedIn) @@ -100,8 +99,7 @@ describe 'Auth:', -> expect(token).to.equal(johnDoeFixture.token) auth.login(janeDoeFixture.credentials, callback) - (token, callback) -> - expect(token).to.be.a.string + (callback) -> auth.getToken(callback) (token, callback) -> diff --git a/lib/token/token.spec.coffee b/lib/token/token.spec.coffee index faeb2191..c4b01bbc 100644 --- a/lib/token/token.spec.coffee +++ b/lib/token/token.spec.coffee @@ -24,7 +24,7 @@ describe 'Token:', -> expect(savedToken).to.equal(johnDoeFixture.token) token.saveToken(janeDoeFixture.token, callback) - (savedToken, callback) -> + (callback) -> token.getToken(callback) (savedToken, callback) ->