4 use RT::Test tests => 39;
6 my ( $url, $m ) = RT::Test->started_ok;
11 '/', '/Ticket/Create.html?Queue=1',
12 '/SelfService/Create.html?Queue=1', '/m/ticket/create?Queue=1'
15 my $root = RT::Test->load_or_create_user( Name => 'root' );
16 ok( $root->id, 'loaded root' );
17 is( $root->EmailAddress, 'root@localhost', 'default root email' );
19 for my $link (@links) {
21 $m->content_contains( '"root@localhost"', "default email in $link" );
24 $root->SetEmailAddress('foo@example.com');
25 is( $root->EmailAddress, 'foo@example.com', 'changed to foo@example.com' );
27 for my $link (@links) {
29 $m->content_lacks( '"root@localhost"', "no default email in $link" );
30 $m->content_contains( '"foo@example.com"', "new email in $link" );
33 $root->SetEmailAddress('root@localhost');
34 is( $root->EmailAddress, 'root@localhost', 'changed back to root@localhost' );
36 for my $link (@links) {
38 $m->content_lacks( '"foo@example.com"', "no previous email in $link" );
39 $m->content_contains( '"root@localhost"', "default email in $link" );