diff --git a/t/02-registration.t b/t/02-registration.t index 83b981cc3a64dc03befb51d4acdd6b0c442d8aa7..cd2201ad9b959baa269aee25530f25b9c03dcee7 100644 --- a/t/02-registration.t +++ b/t/02-registration.t @@ -43,6 +43,7 @@ my $csrf_token $t->post_ok( '/register' => form => { csrf_token => $csrf_token, + dt => 1, user => 'someone', email => 'foo@example.org', password => 'foofoofoo', @@ -51,10 +52,23 @@ $t->post_ok( ); $t->status_is(200)->content_like(qr{Verifizierungslink}); +# Failed registration (CSRF) +$t->post_ok( + '/register' => form => { + csrf_token => $csrf_token, + user => 'noone', + email => 'foo2@example.org', + password => 'foofoofoo', + password2 => 'foofoofoo', + } +); +$t->status_is(200)->content_like(qr{CSRF}); + # Failed registration (user name not available) $t->post_ok( '/register' => form => { csrf_token => $csrf_token, + dt => 1, user => 'someone', email => 'foo@example.org', password => 'foofoofoo', diff --git a/t/11-journey-stats.t b/t/11-journey-stats.t index 808a15c20f6e73854eb0d76102710236120f5e98..e50c5b69d7d1b411589109337e818ae7882da971 100644 --- a/t/11-journey-stats.t +++ b/t/11-journey-stats.t @@ -43,6 +43,7 @@ my $csrf_token $t->post_ok( '/register' => form => { csrf_token => $csrf_token, + dt => 1, user => 'someone', email => 'foo@example.org', password => 'foofoofoo', diff --git a/t/12-journey-edit.t b/t/12-journey-edit.t index 941ff9511b41c2334380e7a4c4e16056d2a54de0..1f00b85b0f50a5d8f6f2be864792416c209e74fc 100644 --- a/t/12-journey-edit.t +++ b/t/12-journey-edit.t @@ -45,6 +45,7 @@ my $csrf_token $t->post_ok( '/register' => form => { csrf_token => $csrf_token, + dt => 1, user => 'someone', email => 'foo@example.org', password => 'foofoofoo', diff --git a/t/r-negative-delay.t b/t/r-negative-delay.t index 2b6f271510daa24a32e9c678e0dd471554e10220..7abe1bcaa4a5c75ea488c300c305c828f3cc30d0 100644 --- a/t/r-negative-delay.t +++ b/t/r-negative-delay.t @@ -44,6 +44,7 @@ my $csrf_token $t->post_ok( '/register' => form => { csrf_token => $csrf_token, + dt => 1, user => 'someone', email => 'foo@example.org', password => 'foofoofoo',