Tests fixed
This commit is contained in:
parent
ef2e0627e1
commit
6cdc8891c3
9 changed files with 13 additions and 0 deletions
|
@ -21,6 +21,7 @@ $schema->resultset('Organisation')->create({
|
|||
name => 'Shinra Electric Power Company',
|
||||
street_name => 'Sector 0, Midgar, Eastern Continent',
|
||||
town => 'Gaia',
|
||||
sector => 'A',
|
||||
postcode => 'WC1E 6AD',
|
||||
});
|
||||
|
||||
|
@ -53,6 +54,7 @@ $t->post_ok('/admin/organisations/valid/1/edit', form => {
|
|||
name => 'Shinra Electric Power Company',
|
||||
street_name => 'Sector 0, Midgar, Eastern Continent',
|
||||
town => 'Gaia',
|
||||
sector => 'A',
|
||||
postcode => 'WC1E 6AD',
|
||||
})->status_is(200)->content_like(qr/Updated Organisation/);
|
||||
|
||||
|
@ -60,6 +62,7 @@ $t->post_ok('/admin/organisations/valid/1/edit', form => {
|
|||
$t->post_ok('/admin/organisations/valid/1/edit', form => {
|
||||
name => 'Shinra Electric Power Company',
|
||||
street_name => 'Sector 0, Midgar, Eastern Continent',
|
||||
sector => 'A',
|
||||
postcode => 'WC1E 6AD',
|
||||
})->content_like(qr/The validation has failed/);
|
||||
|
||||
|
@ -83,6 +86,7 @@ $t->post_ok('/admin/organisations/add/submit', form => {
|
|||
name => 'Wall Market',
|
||||
street_name => 'Slums, Sector 6',
|
||||
town => 'Midgar',
|
||||
sector => 'A',
|
||||
postcode => 'TN35 5AQ',
|
||||
})->status_is(200)->content_like(qr/Added Organisation/);
|
||||
|
||||
|
|
|
@ -342,6 +342,7 @@ $testJson = {
|
|||
'email' => 'org@org.com',
|
||||
'postcode' => 'LA1 1AA',
|
||||
'password' => 'Meh',
|
||||
'sector' => 'A',
|
||||
};
|
||||
$t->post_ok('/api/register' => json => $testJson)
|
||||
->status_is(400)
|
||||
|
@ -360,6 +361,7 @@ $testJson = {
|
|||
'password' => 'Meh',
|
||||
'street_name' => 'mary lane testing....',
|
||||
'town' => 'Lancaster',
|
||||
'sector' => 'A',
|
||||
};
|
||||
$t->post_ok('/api/register' => json => $testJson)
|
||||
->status_is(200)
|
||||
|
|
|
@ -55,6 +55,7 @@ $testJson = {
|
|||
'password' => $passwordBilly,
|
||||
'street_name' => 'Market St',
|
||||
'town' => 'Lancaster',
|
||||
'sector' => 'A',
|
||||
};
|
||||
$t->post_ok('/api/register' => json => $testJson)
|
||||
->status_is(200)
|
||||
|
|
|
@ -28,6 +28,7 @@ my $org = {
|
|||
town => 'Lancaster',
|
||||
postcode => 'LA1 1AA',
|
||||
password => 'abc123',
|
||||
sector => 'A',
|
||||
};
|
||||
|
||||
$schema->resultset('AccountToken')->create({ name => $user->{token} });
|
||||
|
|
|
@ -56,6 +56,7 @@ my $org = {
|
|||
name => 'Test Org',
|
||||
street_name => 'Test Street',
|
||||
town => 'Lancaster',
|
||||
sector => 'A',
|
||||
postcode => 'LA1 1AA',
|
||||
password => 'abc123',
|
||||
};
|
||||
|
|
|
@ -81,6 +81,7 @@ $testJson = {
|
|||
'password' => $passwordBilly,
|
||||
'street_name' => 'Chocobo Farm, Eastern Continent',
|
||||
'town' => 'Gaia',
|
||||
'sector' => 'A',
|
||||
};
|
||||
$t->post_ok('/api/register' => json => $testJson)
|
||||
->status_is(200)
|
||||
|
|
|
@ -58,6 +58,7 @@ my $org = {
|
|||
town => 'Lancaster',
|
||||
postcode => 'LA1 1AA',
|
||||
password => 'abc123',
|
||||
sector => 'A',
|
||||
};
|
||||
|
||||
$schema->resultset('AccountToken')->create({ name => $_->{token} })
|
||||
|
|
|
@ -58,6 +58,7 @@ my $org = {
|
|||
town => 'Lancaster',
|
||||
postcode => 'LA1 1AA',
|
||||
password => 'abc123',
|
||||
sector => 'A',
|
||||
};
|
||||
|
||||
$schema->resultset('AccountToken')->create({ name => $_->{token} })
|
||||
|
|
|
@ -58,6 +58,7 @@ my $org = {
|
|||
town => 'Lancaster',
|
||||
postcode => 'LA1 1AA',
|
||||
password => 'abc123',
|
||||
sector => 'A',
|
||||
};
|
||||
|
||||
$schema->resultset('AccountToken')->create({ name => $_->{token} })
|
||||
|
|
Reference in a new issue