Add abstract model Key
This commit is contained in:
parent
9be8f349f4
commit
cd513e3256
3 changed files with 13 additions and 1 deletions
5
app/models/key.rb
Normal file
5
app/models/key.rb
Normal file
|
@ -0,0 +1,5 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
class Key < ApplicationRecord
|
||||
self.abstract_class = true
|
||||
end
|
|
@ -1,6 +1,6 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
class RSAKey < ApplicationRecord
|
||||
class RSAKey < Key
|
||||
PRIVATE_KEY_CLEAR_DELAY = 12.hours.freeze
|
||||
|
||||
attr_accessor :private_key_pem, :private_key_pem_secret
|
||||
|
|
7
spec/models/key_spec.rb
Normal file
7
spec/models/key_spec.rb
Normal file
|
@ -0,0 +1,7 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
require 'rails_helper'
|
||||
|
||||
RSpec.describe Key do
|
||||
pending "add some examples to (or delete) #{__FILE__}"
|
||||
end
|
Reference in a new issue