mirror of
https://github.com/internetee/registry.git
synced 2025-07-25 20:18:22 +02:00
Dnskey spec
This commit is contained in:
parent
7a647682df
commit
da6b115f6f
4 changed files with 25 additions and 0 deletions
16
spec/models/dnskey_spec.rb
Normal file
16
spec/models/dnskey_spec.rb
Normal file
|
@ -0,0 +1,16 @@
|
|||
require 'rails_helper'
|
||||
|
||||
describe Dnskey do
|
||||
before(:each) { Fabricate(:domain_validation_setting_group) }
|
||||
|
||||
it { should belong_to(:domain) }
|
||||
|
||||
it 'generates digest' do
|
||||
|
||||
d = Fabricate(:domain, name: 'ria.ee')
|
||||
ds = d.dnskeys.first
|
||||
|
||||
ds.generate_digest
|
||||
expect(ds.ds_digest).to eq('0B62D1BC64EFD1EE652FB102BDF1011BF514CCD9A1A0CFB7472AEA3B01F38C92')
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue