|
52 | 52 | it 'returns updated user' do |
53 | 53 | VCR.use_cassette 'update_user' do |
54 | 54 | resp, = client.update_user(USERS_USER_ID, |
55 | | - profile: { |
56 | | - firstName: "Bob", |
57 | | - lastName: "User", |
58 | | - |
59 | | - |
60 | | - }) |
| 55 | + profile: { |
| 56 | + firstName: "Bob", |
| 57 | + lastName: "User", |
| 58 | + |
| 59 | + |
| 60 | + }) |
61 | 61 | expect(resp.profile.firstName).to be == 'Bob' |
62 | 62 | end |
63 | 63 | end |
|
67 | 67 | it 'returns updated user' do |
68 | 68 | VCR.use_cassette 'update_user_partial' do |
69 | 69 | resp, = client.update_user(USERS_USER_ID, |
70 | | - profile: { |
71 | | - firstName: "Bob", |
72 | | - lastName: "User", |
73 | | - |
74 | | - |
75 | | - }, |
76 | | - partial: true) |
| 70 | + profile: { |
| 71 | + firstName: "Bob", |
| 72 | + lastName: "User", |
| 73 | + |
| 74 | + |
| 75 | + }, |
| 76 | + partial: true) |
77 | 77 | expect(resp.profile.firstName).to be == 'Bob' |
78 | 78 | end |
79 | 79 | end |
|
83 | 83 | it 'returns updated user' do |
84 | 84 | VCR.use_cassette 'update_profile' do |
85 | 85 | resp, = client.update_profile(USERS_USER_ID, |
86 | | - profile: { |
87 | | - firstName: "Other Bob", |
88 | | - lastName: "User", |
89 | | - |
90 | | - |
91 | | - }) |
| 86 | + profile: { |
| 87 | + firstName: "Other Bob", |
| 88 | + lastName: "User", |
| 89 | + |
| 90 | + |
| 91 | + }) |
92 | 92 | expect(resp.profile.firstName).to be == 'Other Bob' |
93 | 93 | end |
94 | 94 | end |
|
187 | 187 | describe '#forgot_password' do |
188 | 188 | it 'returns an empty object by default.' do |
189 | 189 | VCR.use_cassette 'forgot_password' do |
190 | | - resp, = client.forgot_password(USERS_USER_ID, |
| 190 | + resp, = client.forgot_password( |
| 191 | + USERS_USER_ID, |
191 | 192 | password: { value: "123Password!" }, |
192 | | - recovery_question: { answer: "A woodchuck could chuck as much as he could chuck." }) |
| 193 | + recovery_question: { answer: "A woodchuck could chuck as much as he could chuck." } |
| 194 | + ) |
193 | 195 | expect(resp.password.to_h).to be == {} |
194 | 196 | end |
195 | 197 | end |
|
199 | 201 | it 'returns credentials of the user' do |
200 | 202 | VCR.use_cassette 'change_password' do |
201 | 203 | _, status = client.change_password(USERS_USER_ID, |
202 | | - oldPassword: { value: "uTVM,TPw55" }, |
203 | | - newPassword: { value: "NewPassword1234!" }) |
| 204 | + oldPassword: { value: "uTVM,TPw55" }, |
| 205 | + newPassword: { value: "NewPassword1234!" }) |
204 | 206 | expect(status).to be(200) |
205 | 207 | end |
206 | 208 | end |
|
210 | 212 | it 'returns credentials of the user' do |
211 | 213 | VCR.use_cassette 'change_recovery_question' do |
212 | 214 | resp, = client.change_recovery_question(USERS_USER_ID, |
213 | | - password: { value: "NewPassword1234!" }, |
214 | | - recovery_question: { |
215 | | - question: "Where is Shopify's HQ?", |
216 | | - answer: "Ottawa" |
217 | | - }) |
| 215 | + password: { value: "NewPassword1234!" }, |
| 216 | + recovery_question: { |
| 217 | + question: "Where is Shopify's HQ?", |
| 218 | + answer: "Ottawa" |
| 219 | + }) |
218 | 220 | expect(resp.recovery_question.question).to be == "Where is Shopify's HQ?" |
219 | 221 | end |
220 | 222 | end |
|
0 commit comments