diff options
author | Mike Lewis <mlewis@gitlab.com> | 2019-03-07 15:59:00 +0000 |
---|---|---|
committer | Mike Lewis <mlewis@gitlab.com> | 2019-03-07 15:59:00 +0000 |
commit | dbd7309a16bd3abc6c586b6c2df2beb317cfef95 (patch) | |
tree | 3fdd719c926ac80285f0dc93ef975625657d0fbb /spec/models/appearance_spec.rb | |
parent | 7be248334b350091e83d0335bf0c263071c6a67f (diff) | |
parent | b63efb09a5c864047924cd2d84527b47dd563d5f (diff) | |
download | gitlab-ce-reply-to-comment-documentation.tar.gz |
Merge branch 'master' into 'reply-to-comment-documentation'reply-to-comment-documentation
# Conflicts:
# doc/user/discussions/index.md
Diffstat (limited to 'spec/models/appearance_spec.rb')
-rw-r--r-- | spec/models/appearance_spec.rb | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/spec/models/appearance_spec.rb b/spec/models/appearance_spec.rb index 28d482adebf..3e95aa2b5dd 100644 --- a/spec/models/appearance_spec.rb +++ b/spec/models/appearance_spec.rb @@ -78,4 +78,22 @@ describe Appearance do it { is_expected.to allow_value(hex).for(:message_font_color) } it { is_expected.not_to allow_value('000').for(:message_font_color) } end + + describe 'email_header_and_footer_enabled' do + context 'default email_header_and_footer_enabled flag value' do + it 'returns email_header_and_footer_enabled as true' do + appearance = build(:appearance) + + expect(appearance.email_header_and_footer_enabled?).to eq(false) + end + end + + context 'when setting email_header_and_footer_enabled flag value' do + it 'returns email_header_and_footer_enabled as true' do + appearance = build(:appearance, email_header_and_footer_enabled: true) + + expect(appearance.email_header_and_footer_enabled?).to eq(true) + end + end + end end |