|
53 | 53 |
|
54 | 54 | describe '#extra' do
|
55 | 55 | context 'when using a mock request' do
|
56 |
| - it 'has the correct photo' do |
| 56 | + it 'has the correct selfie' do |
57 | 57 | selfie = File.read('spec/fixtures/selfie.txt', encoding: 'utf-8')
|
58 |
| - expect(subject.extra[:photo]).to eql(selfie) |
| 58 | + expect(subject.extra[:selfie]).to eql(selfie) |
59 | 59 | end
|
60 | 60 |
|
61 | 61 | it 'has the correct phone number' do
|
62 |
| - expect(subject.extra[:mobile_number]).to eql('+447474747474') |
| 62 | + expect(subject.extra[:phone_number]).to eql('+447474747474') |
63 | 63 | end
|
64 | 64 | end
|
65 | 65 |
|
|
69 | 69 | end
|
70 | 70 |
|
71 | 71 | it 'has the correct selfie' do
|
72 |
| - expect(subject.extra[:photo]).to eql('photo.png') |
| 72 | + expect(subject.extra[:selfie]).to eql('selfie.png') |
73 | 73 | end
|
74 | 74 |
|
75 | 75 | it 'has the correct given names' do
|
|
81 | 81 | end
|
82 | 82 |
|
83 | 83 | it 'has the correct mobile number' do
|
84 |
| - expect(subject.extra[:mobile_number]).to eql('07474747474') |
| 84 | + expect(subject.extra[:phone_number]).to eql('07474747474') |
| 85 | + end |
| 86 | + |
| 87 | + it 'has the correct email address' do |
| 88 | + expect(subject.extra[:email_address]).to eql('[email protected]') |
85 | 89 | end
|
86 | 90 |
|
87 | 91 | it 'has the correct date of birth' do
|
88 | 92 | expect(subject.extra[:date_of_birth]).to eql('2000.12.12')
|
89 | 93 | end
|
90 | 94 |
|
91 |
| - it 'has the correct address' do |
92 |
| - expect(subject.extra[:address]).to eql('WC2N 4JH') |
| 95 | + it 'has the correct postal address' do |
| 96 | + expect(subject.extra[:postal_address]).to eql('WC2N 4JH') |
93 | 97 | end
|
94 | 98 |
|
95 | 99 | it 'has the correct gender' do
|
|
106 | 110 |
|
107 | 111 | def raw_info_hash
|
108 | 112 | {
|
109 |
| - 'selfie' => 'photo.png', |
| 113 | + 'selfie' => 'selfie.png', |
110 | 114 | 'given_names' => 'Given Names',
|
111 | 115 | 'family_name' => 'Family Name',
|
112 | 116 | 'phone_number' => '07474747474',
|
| 117 | + 'email_address' => '[email protected]', |
113 | 118 | 'date_of_birth' => '2000.12.12',
|
114 |
| - 'post_code' => 'WC2N 4JH', |
| 119 | + 'postal_address' => 'WC2N 4JH', |
115 | 120 | 'gender' => 'male',
|
116 | 121 | 'nationality' => 'British'
|
117 | 122 | }
|
|
0 commit comments