Ability to give a statement
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
require 'rails_helper'
|
||||
|
||||
describe Publicity do
|
||||
it { is_expected.to be_embedded_in(:supporter) }
|
||||
|
||||
it { is_expected.to validate_presence_of(:state) }
|
||||
it { is_expected.to validate_presence_of(:statement) }
|
||||
it { is_expected.to validate_presence_of(:avatar) }
|
||||
end
|
||||
@@ -12,6 +12,8 @@ describe Supporter do
|
||||
it { is_expected.to validate_presence_of(:age_category) }
|
||||
it { is_expected.to validate_presence_of(:language) }
|
||||
|
||||
it { is_expected.to embed_one(:publicity) }
|
||||
|
||||
describe '.counter' do
|
||||
it 'counts only from a certain number on' do
|
||||
allow(Supporter).to receive(:count) { 12 }
|
||||
|
||||
Reference in New Issue
Block a user