diff options
author | Alexis Reigel <mail@koffeinfrei.org> | 2017-07-25 21:35:44 +0300 |
---|---|---|
committer | Alexis Reigel <mail@koffeinfrei.org> | 2017-07-27 16:46:03 +0300 |
commit | 843b1de0dec3e101b323737e4d345c4e58b2a0c3 (patch) | |
tree | e75c17d342d0d0fccbd2b8a261fa0d2bd57c4506 /spec/models/gpg_key_spec.rb | |
parent | 14551424c9fd3a9401559e6d2da34be8d1fdd45c (diff) |
simplify nil handling
Diffstat (limited to 'spec/models/gpg_key_spec.rb')
-rw-r--r-- | spec/models/gpg_key_spec.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/spec/models/gpg_key_spec.rb b/spec/models/gpg_key_spec.rb index 06bdbb59a11..1242f0b2e2a 100644 --- a/spec/models/gpg_key_spec.rb +++ b/spec/models/gpg_key_spec.rb @@ -44,6 +44,10 @@ describe GpgKey do expect(described_class.new(key: " #{key} ").key).to eq(key) end + + it 'does not strip when the key is nil' do + expect(described_class.new(key: nil).key).to be_nil + end end describe '#user_infos' do |