Dnskey spec

This commit is contained in:
Martin Lensment 2014-10-14 11:58:24 +03:00
parent 7a647682df
commit da6b115f6f
4 changed files with 25 additions and 0 deletions

View 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