diff options
-rw-r--r-- | perllib/FixMyStreet/Cobrand/Hackney.pm | 4 | ||||
-rw-r--r-- | t/app/controller/auth_social.t | 8 | ||||
-rw-r--r-- | t/cobrand/hackney.t | 16 |
3 files changed, 27 insertions, 1 deletions
diff --git a/perllib/FixMyStreet/Cobrand/Hackney.pm b/perllib/FixMyStreet/Cobrand/Hackney.pm index c3af134a9..234573e3e 100644 --- a/perllib/FixMyStreet/Cobrand/Hackney.pm +++ b/perllib/FixMyStreet/Cobrand/Hackney.pm @@ -31,6 +31,10 @@ sub disambiguate_location { }; } +sub do_not_reply_email { shift->feature('do_not_reply_email') } + +sub verp_email_domain { shift->feature('verp_email_domain') } + sub get_geocoder { return 'OSM'; # default of Bing gives poor results, let's try overriding. } diff --git a/t/app/controller/auth_social.t b/t/app/controller/auth_social.t index e56fcda98..1f6889dcc 100644 --- a/t/app/controller/auth_social.t +++ b/t/app/controller/auth_social.t @@ -118,7 +118,13 @@ for my $test ( token_uri => 'http://oidc.example.org/oauth2/v2.0/token_google', allowed_domains => [ 'example.org' ], } - } + }, + do_not_reply_email => { + hackney => 'fms-hackney-DO-NOT-REPLY@hackney-example.com', + }, + verp_email_domain => { + hackney => 'hackney-example.com', + }, } }, email => $mech->uniquify_email('oidc_google@example.org'), diff --git a/t/cobrand/hackney.t b/t/cobrand/hackney.t index 82fefc15b..b5a629e33 100644 --- a/t/cobrand/hackney.t +++ b/t/cobrand/hackney.t @@ -85,6 +85,14 @@ subtest "check moderation label uses correct name" => sub { FixMyStreet::override_config { MAPIT_URL => 'http://mapit.uk/', ALLOWED_COBRANDS => ['hackney'], + COBRAND_FEATURES => { + do_not_reply_email => { + hackney => 'fms-hackney-DO-NOT-REPLY@hackney-example.com', + }, + verp_email_domain => { + hackney => 'hackney-example.com', + }, + }, }, sub { $mech->log_out_ok; $mech->log_in_ok( $hackney_user->email ); @@ -139,6 +147,14 @@ subtest "sends branded confirmation emails" => sub { FixMyStreet::override_config { ALLOWED_COBRANDS => [ 'hackney' ], MAPIT_URL => 'http://mapit.uk/', + COBRAND_FEATURES => { + do_not_reply_email => { + hackney => 'fms-hackney-DO-NOT-REPLY@hackney-example.com', + }, + verp_email_domain => { + hackney => 'hackney-example.com', + }, + }, }, sub { $mech->submit_form_ok( { with_fields => { pc => 'E8 1DY', } }, "submit location" ); |