diff options
Diffstat (limited to 'spec/models/oauth_access_token_spec.rb')
-rw-r--r-- | spec/models/oauth_access_token_spec.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/spec/models/oauth_access_token_spec.rb b/spec/models/oauth_access_token_spec.rb index 5fa590eab58..b21a2bf2079 100644 --- a/spec/models/oauth_access_token_spec.rb +++ b/spec/models/oauth_access_token_spec.rb @@ -32,7 +32,7 @@ RSpec.describe OauthAccessToken do end it 'finds a token by plaintext token' do - expect(described_class.by_token(token.plaintext_token)).to be_a(OauthAccessToken) + expect(described_class.by_token(token.plaintext_token)).to be_a(described_class) end context 'when the token is stored in plaintext' do @@ -43,7 +43,7 @@ RSpec.describe OauthAccessToken do end it 'falls back to plaintext token comparison' do - expect(described_class.by_token(plaintext_token)).to be_a(OauthAccessToken) + expect(described_class.by_token(plaintext_token)).to be_a(described_class) end end end @@ -57,7 +57,7 @@ RSpec.describe OauthAccessToken do describe '#expires_in' do context 'when token has expires_in value set' do it 'uses the expires_in value' do - token = OauthAccessToken.new(expires_in: 1.minute) + token = described_class.new(expires_in: 1.minute) expect(token).to be_valid end @@ -65,7 +65,7 @@ RSpec.describe OauthAccessToken do context 'when token has nil expires_in' do it 'uses default value' do - token = OauthAccessToken.new(expires_in: nil) + token = described_class.new(expires_in: nil) expect(token).to be_invalid end |