aboutsummaryrefslogtreecommitdiffstats
path: root/t/app/controller/my.t
blob: 1ed6806a45730aad43187ba775f1dfd76f666e9c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
use strict;
use warnings;

use Test::More tests => 11;

use FixMyStreet::TestMech;
my $mech = FixMyStreet::TestMech->new;

$mech->get_ok('/my');
is $mech->uri->path, '/auth', "got sent to the login page";

# login
my $user = $mech->log_in_ok( 'test@example.com' );
$mech->get_ok('/my');
is $mech->uri->path, '/my', "stayed on '/my/' page";

# cleanup
$mech->delete_user( $user );