File: none_spec.rb

package info (click to toggle)
ruby-jwt 3.1.2-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 876 kB
  • sloc: ruby: 5,550; makefile: 4
file content (17 lines) | stat: -rw-r--r-- 359 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# frozen_string_literal: true

RSpec.describe JWT::JWA::None do
  subject { described_class.new }

  describe '#sign' do
    it 'returns an empty string' do
      expect(subject.sign('data', 'key')).to eq('')
    end
  end

  describe '#verify' do
    it 'returns true' do
      expect(subject.verify('data', 'signature', 'key')).to be true
    end
  end
end