diff options
author | Matthew Somerville <matthew-github@dracos.co.uk> | 2017-09-20 14:36:12 +0100 |
---|---|---|
committer | Matthew Somerville <matthew-github@dracos.co.uk> | 2017-09-30 15:04:06 +0100 |
commit | d0ae2a420905dbd0b79141d88e2c47956d1d65b2 (patch) | |
tree | c6d7abbb7a33fef2fa3af9c5684d61a6adf0eb1f /t/app/controller/auth_social.t | |
parent | bfdae700a840b74595bb4798ae6d50bb9172fa72 (diff) |
Add ability to log in on /auth via text.
A confirmation code is sent via Twilio to be entered on the site.
Diffstat (limited to 't/app/controller/auth_social.t')
-rw-r--r-- | t/app/controller/auth_social.t | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/t/app/controller/auth_social.t b/t/app/controller/auth_social.t index 726d264bd..d16a0102e 100644 --- a/t/app/controller/auth_social.t +++ b/t/app/controller/auth_social.t @@ -104,8 +104,10 @@ for my $fb_state ( 'refused', 'no email', 'existing UID', 'okay' ) { # and the ID carries through the confirmation if ($page eq 'update') { $fields->{rznvy} = $fb_email; - } else { + } elsif ($page eq 'report') { $fields->{email} = $fb_email; + } else { + $fields->{username} = $fb_email; } $fields->{name} = 'Ffion Tester'; $mech->submit_form(with_fields => $fields); @@ -216,8 +218,10 @@ for my $tw_state ( 'refused', 'existing UID', 'no email' ) { # and the ID carries through the confirmation if ($page eq 'update') { $fields->{rznvy} = $tw_email; - } else { + } elsif ($page eq 'report') { $fields->{email} = $tw_email; + } else { + $fields->{username} = $tw_email; } $fields->{name} = 'Ffion Tester'; $mech->submit_form(with_fields => $fields); |