aboutsummaryrefslogtreecommitdiffstats
path: root/t/app
diff options
context:
space:
mode:
Diffstat (limited to 't/app')
-rw-r--r--t/app/controller/admin.t4
-rw-r--r--t/app/controller/dashboard.t4
-rw-r--r--t/app/controller/report_new.t14
-rw-r--r--t/app/controller/report_new_open311.t4
-rw-r--r--t/app/model/problem.t16
-rw-r--r--t/app/sendreport/email.t2
6 files changed, 22 insertions, 22 deletions
diff --git a/t/app/controller/admin.t b/t/app/controller/admin.t
index 644e488b2..71a391c59 100644
--- a/t/app/controller/admin.t
+++ b/t/app/controller/admin.t
@@ -151,12 +151,12 @@ $mech->content_contains("$host/around");
subtest 'check contact creation' => sub {
my $contact = FixMyStreet::App->model('DB::Contact')->search(
- { area_id => 2650, category => [ 'test category', 'test/category' ] }
+ { body_id => 2650, category => [ 'test category', 'test/category' ] }
);
$contact->delete_all;
my $history = FixMyStreet::App->model('DB::ContactsHistory')->search(
- { area_id => 2650, category => [ 'test category', 'test/category' ] }
+ { body_id => 2650, category => [ 'test category', 'test/category' ] }
);
$history->delete_all;
diff --git a/t/app/controller/dashboard.t b/t/app/controller/dashboard.t
index 945f7a9d7..307943abd 100644
--- a/t/app/controller/dashboard.t
+++ b/t/app/controller/dashboard.t
@@ -44,7 +44,7 @@ $mech->submit_form_ok( {
$mech->content_contains( 'City of Edinburgh' );
-FixMyStreet::App->model('DB::Contact')->search( { area_id => $test_council } )
+FixMyStreet::App->model('DB::Contact')->search( { body_id => $test_council } )
->delete;
delete_problems();
@@ -53,7 +53,7 @@ my @cats = qw( Grafitti Litter Potholes Other );
for my $contact ( @cats ) {
FixMyStreet::App->model('DB::Contact')->create(
{
- area_id => $test_council,
+ body_id => $test_council,
category => $contact,
email => "$contact\@example.org",
confirmed => 1,
diff --git a/t/app/controller/report_new.t b/t/app/controller/report_new.t
index 77afb071c..92943bde9 100644
--- a/t/app/controller/report_new.t
+++ b/t/app/controller/report_new.t
@@ -39,43 +39,43 @@ FixMyStreet::App->model('DB::Contact')->search( {
} )->delete;
my $contact1 = FixMyStreet::App->model('DB::Contact')->find_or_create( {
%contact_params,
- area_id => 2651, # Edinburgh
+ body_id => 2651, # Edinburgh
category => 'Street lighting',
email => 'highways@example.com',
} );
my $contact2 = FixMyStreet::App->model('DB::Contact')->find_or_create( {
%contact_params,
- area_id => 2226, # Gloucestershire
+ body_id => 2226, # Gloucestershire
category => 'Potholes',
email => 'potholes@example.com',
} );
my $contact3 = FixMyStreet::App->model('DB::Contact')->find_or_create( {
%contact_params,
- area_id => 2326, # Cheltenham
+ body_id => 2326, # Cheltenham
category => 'Trees',
email => 'trees@example.com',
} );
my $contact4 = FixMyStreet::App->model('DB::Contact')->find_or_create( {
%contact_params,
- area_id => 2482, # Bromley
+ body_id => 2482, # Bromley
category => 'Trees',
email => 'trees@example.com',
} );
my $contact5 = FixMyStreet::App->model('DB::Contact')->find_or_create( {
%contact_params,
- area_id => 2651, # Edinburgh
+ body_id => 2651, # Edinburgh
category => 'Trees',
email => 'trees@example.com',
} );
my $contact6 = FixMyStreet::App->model('DB::Contact')->find_or_create( {
%contact_params,
- area_id => 2434, # Lichfield
+ body_id => 2434, # Lichfield
category => 'Trees',
email => 'trees@example.com',
} );
my $contact7 = FixMyStreet::App->model('DB::Contact')->find_or_create( {
%contact_params,
- area_id => 2240, # Lichfield
+ body_id => 2240, # Lichfield
category => 'Street lighting',
email => 'highways@example.com',
} );
diff --git a/t/app/controller/report_new_open311.t b/t/app/controller/report_new_open311.t
index 4b009c746..e9ada9f41 100644
--- a/t/app/controller/report_new_open311.t
+++ b/t/app/controller/report_new_open311.t
@@ -24,7 +24,7 @@ my %contact_params = (
# Let's make some contacts to send things to!
my $contact1 = FixMyStreet::App->model('DB::Contact')->find_or_create( {
%contact_params,
- area_id => 2651, # Edinburgh
+ body_id => 2651, # Edinburgh
category => 'Street lighting',
email => '100',
extra => [ { description => 'Lamppost number', code => 'number', required => 'True' },
@@ -35,7 +35,7 @@ my $contact1 = FixMyStreet::App->model('DB::Contact')->find_or_create( {
} );
my $contact2 = FixMyStreet::App->model('DB::Contact')->find_or_create( {
%contact_params,
- area_id => 2651, # Edinburgh
+ body_id => 2651, # Edinburgh
category => 'Graffiti Removal',
email => '101',
} );
diff --git a/t/app/model/problem.t b/t/app/model/problem.t
index 9aa52c3cf..baec6baf0 100644
--- a/t/app/model/problem.t
+++ b/t/app/model/problem.t
@@ -361,36 +361,36 @@ FixMyStreet::App->model('DB::Contact')->search( {
} )->delete;
my @contacts;
for my $contact ( {
- area_id => 2651, # Edinburgh
+ body_id => 2651, # Edinburgh
category => 'potholes',
email => 'test@example.org',
}, {
- area_id => 2226, # Gloucestershire
+ body_id => 2226, # Gloucestershire
category => 'potholes',
email => '2226@example.org',
}, {
- area_id => 2326, # Cheltenham
+ body_id => 2326, # Cheltenham
category => 'potholes',
email => '2326@example.org',
}, {
- area_id => 2434, # Lichfield
+ body_id => 2434, # Lichfield
category => 'potholes',
email => 'trees@example.com',
}, {
- area_id => 2240, # Staffordshire
+ body_id => 2240, # Staffordshire
category => 'potholes',
email => 'highways@example.com',
}, {
- area_id => 14279, # Ballymoney
+ body_id => 14279, # Ballymoney
category => 'Street lighting',
email => 'roads.western@drdni.example.org',
}, {
- area_id => 14279, # Ballymoney
+ body_id => 14279, # Ballymoney
category => 'Graffiti',
email => 'highways@example.com',
}, {
confirmed => 0,
- area_id => 2636, # Isle of Wight
+ body_id => 2636, # Isle of Wight
category => 'potholes',
email => '2636@example.com',
} ) {
diff --git a/t/app/sendreport/email.t b/t/app/sendreport/email.t
index f0e1f153a..04b3854cc 100644
--- a/t/app/sendreport/email.t
+++ b/t/app/sendreport/email.t
@@ -16,7 +16,7 @@ my $e = FixMyStreet::SendReport::Email->new();
my $contact = FixMyStreet::App->model('DB::Contact')->find_or_create(
email => 'council@example.com',
- area_id => 1000,
+ body_id => 1000,
category => 'category',
confirmed => 1,
deleted => 0,