aboutsummaryrefslogtreecommitdiffstats
path: root/t/cobrand/zurich.t
diff options
context:
space:
mode:
Diffstat (limited to 't/cobrand/zurich.t')
-rw-r--r--t/cobrand/zurich.t11
1 files changed, 10 insertions, 1 deletions
diff --git a/t/cobrand/zurich.t b/t/cobrand/zurich.t
index d8e39c304..8def10d4f 100644
--- a/t/cobrand/zurich.t
+++ b/t/cobrand/zurich.t
@@ -98,7 +98,7 @@ my $superuser;
subtest "set up superuser" => sub {
$superuser = $mech->log_in_ok( 'super@example.org' );
# a user from body $zurich is a superuser, as $zurich has no parent id!
- $superuser->update({ from_body => $zurich->id });
+ $superuser->update({ name => 'Superuser', from_body => $zurich->id });
$EXISTING_REPORT_COUNT = get_export_rows_count($mech);
$mech->log_out_ok;
};
@@ -989,6 +989,15 @@ $mech->log_out_ok;
subtest 'users at the top level can be edited' => sub {
$mech->log_in_ok( $superuser->email );
$mech->get_ok('/admin/users/' . $superuser->id );
+ $mech->content_contains('name="flagged">');
+ $mech->submit_form_ok({ with_fields => { flagged => 1 } });
+ $superuser->discard_changes;
+ is $superuser->flagged, 1, 'Marked as flagged';
+ $mech->get_ok('/admin/users/' . $superuser->id );
+ $mech->content_contains('name="flagged" checked');
+ $mech->submit_form_ok({ with_fields => { flagged => 0 } });
+ $superuser->discard_changes;
+ is $superuser->flagged, 0, 'Unmarked';
};
subtest 'A visit to /reports is okay' => sub {