Commit 41c96c45 authored by Alexis Reigel's avatar Alexis Reigel

test with a gpg key with multiple emails

parent 5ce61120
......@@ -16,7 +16,7 @@ feature 'Profile > GPG Keys', :gpg do
fill_in('Key', with: attributes_for(:gpg_key)[:key])
click_button('Add key')
expect(page).to have_content(GpgHelpers::User1.email)
expect(page).to have_content(GpgHelpers::User1.emails.join)
expect(page).to have_content(GpgHelpers::User1.fingerprint)
end
end
......@@ -25,7 +25,7 @@ feature 'Profile > GPG Keys', :gpg do
create(:gpg_key, user: user)
visit profile_gpg_keys_path
expect(page).to have_content(GpgHelpers::User1.email)
expect(page).to have_content(GpgHelpers::User1.emails.join)
expect(page).to have_content(GpgHelpers::User1.fingerprint)
end
......
......@@ -59,7 +59,7 @@ describe GpgKey do
it 'returns the emails from the gpg key' do
gpg_key = create :gpg_key, key: GpgHelpers::User1.public_key
expect(gpg_key.emails).to eq [GpgHelpers::User1.email]
expect(gpg_key.emails).to eq GpgHelpers::User1.emails
end
end
end
......@@ -98,8 +98,8 @@ module GpgHelpers
'5F7EA3981A5845B141ABD522CCFBE19F00AC8B1D'
end
def email
'nannie.bernhard@example.com'
def emails
['nannie.bernhard@example.com']
end
end
......@@ -161,15 +161,20 @@ module GpgHelpers
iLgEEwECACIFAliuqioCGwMGCwkIBwMCBhUIAgkKCwQWAgMBAh4BAheAAAoJEL+d
kl+RHv1lQhsD/0LDi008hCeoZdGMuwy2N5FMUusYg/X1tRQ6E0JcYYjvvE5oIZoX
bVN0yLLD99P0rt6TSlt05CC7RPVPCNpKxKbF+TZMjMJiOi13XmY5Yti77ZMdBZtD
7HeBzjkWCVuR6k8eIwy83niHGI6p6G87Q6XxvDjQ7wdBCNBpwkzmTYIBuI0EWK6q
KgEEAN7mdR1U5xtmWfE6OXQoEBP4DlubIEtRPQGYs+yYDg+5cNK2Hta+Js8LzBwJ
0JhWTQhExid5lSJar+jlziu2F8tHiODySu6+iZDgTh3iHIjpHQwvFdhndcy7rtW5
JwWBstRHDV5FnXoA13c1zVW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KEY BLOCK-----
KEY
end
......@@ -182,8 +187,8 @@ module GpgHelpers
'6D494CA6FC90C0CAE0910E42BF9D925F911EFD65'
end
def email
'bette.cartwright@example.com'
def emails
['bette.cartwright@example.com', 'bette.cartwright@example.net']
end
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment