diff options
author | Byron Jones <glob@mozilla.com> | 2015-09-09 09:22:31 +0200 |
---|---|---|
committer | Byron Jones <glob@mozilla.com> | 2015-09-09 09:22:31 +0200 |
commit | 54b1008f41859c506a59f13925bdd9be26983619 (patch) | |
tree | 9f524dd6e44fd7162abbccfdb5b6d0c9d76f7c3f | |
parent | 774494c2af95f90bff94994f7a2d9374f17c24f5 (diff) | |
download | bugzilla-54b1008f41859c506a59f13925bdd9be26983619.tar.gz bugzilla-54b1008f41859c506a59f13925bdd9be26983619.tar.xz |
Bug 1202461 - update test script for account creation
-rw-r--r-- | qa/t/test_create_user_accounts.t | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/qa/t/test_create_user_accounts.t b/qa/t/test_create_user_accounts.t index 18b555aaf..e1da8bbec 100644 --- a/qa/t/test_create_user_accounts.t +++ b/qa/t/test_create_user_accounts.t @@ -18,7 +18,7 @@ my ($sel, $config) = get_selenium(); # Set the email regexp for new bugzilla accounts to end with @bugzilla.test. log_in($sel, $config, 'admin'); -set_parameters($sel, { "User Authentication" => {"createemailregexp" => {type => "text", value => '[^@]+@bugzilla\.test'}} }); +set_parameters($sel, { "User Authentication" => {"createemailregexp" => {type => "text", value => '[^@]+@bugzilla\.test$'}} }); logout($sel); # Create a valid account. We need to randomize the login address, because a request @@ -51,7 +51,7 @@ my $error_msg = trim($sel->get_text("error_msg")); ok($error_msg =~ /Please wait a while and try again/, "Too soon for this account"); # These accounts do not pass the regexp. -my @accounts = ('test@yahoo.com', 'test@bugzilla.net', 'test@bugzilla..test'); +my @accounts = ('test@yahoo.com', 'test@bugzilla.net', 'test@bugzilla.test.com'); foreach my $account (@accounts) { $sel->click_ok("link=New Account"); $sel->wait_for_page_to_load_ok(WAIT_TIME); @@ -63,16 +63,8 @@ foreach my $account (@accounts) { $sel->is_text_present_ok("User account creation has been restricted."); } -# These accounts are illegal and should cause a javascript alert. -@accounts = qw( - test\bugzilla@bugzilla.test - testbugzilla.test - test@bugzilla - test@bugzilla. - 'test'@bugzilla.test - test&test@bugzilla.test - [test]@bugzilla.test -); +# These accounts are illegal. +@accounts = ('test\bugzilla@bugzilla.test', 'test@bugzilla.org@bugzilla.test', 'test@bugzilla..test'); foreach my $account (@accounts) { $sel->click_ok("link=New Account"); $sel->wait_for_page_to_load_ok(WAIT_TIME); |