diff options
author | Matthew Somerville <matthew@mysociety.org> | 2012-12-13 15:48:48 +0000 |
---|---|---|
committer | Matthew Somerville <matthew@mysociety.org> | 2012-12-15 00:11:06 +0000 |
commit | 9fb130a0ab1bd36e977439b7697fba5fec5b1f00 (patch) | |
tree | e9c8f3fce2ecf110172b9359e48c436b10e66fee /perllib/FixMyStreet/TestMech.pm | |
parent | 48d290abd549a623e3af4b62127668cf92018d9c (diff) |
Rename council column to bodies_str, and all the related code.
Diffstat (limited to 'perllib/FixMyStreet/TestMech.pm')
-rw-r--r-- | perllib/FixMyStreet/TestMech.pm | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/perllib/FixMyStreet/TestMech.pm b/perllib/FixMyStreet/TestMech.pm index 7f81c0fc2..30807c4e2 100644 --- a/perllib/FixMyStreet/TestMech.pm +++ b/perllib/FixMyStreet/TestMech.pm @@ -519,11 +519,11 @@ sub get_ok_json { return decode_json( $res->content ); } -sub delete_problems_for_council { +sub delete_problems_for_body { my $mech = shift; - my $council = shift; + my $body = shift; - my $reports = FixMyStreet::App->model('DB::Problem')->search( { council => $council } ); + my $reports = FixMyStreet::App->model('DB::Problem')->search( { bodies_str => $body } ); if ( $reports ) { for my $r ( $reports->all ) { $r->comments->delete; @@ -532,8 +532,8 @@ sub delete_problems_for_council { } } -sub create_problems_for_council { - my ( $mech, $count, $council, $title, $params ) = @_; +sub create_problems_for_body { + my ( $mech, $count, $body, $title, $params ) = @_; my $dt = $params->{dt} || DateTime->now(); @@ -549,11 +549,11 @@ sub create_problems_for_council { while ($count) { my $default_params = { postcode => 'SW1A 1AA', - council => $council, + bodies_str => $body, areas => ',105255,11806,11828,2247,2504,', category => 'Other', - title => "$title Test $count for $council", - detail => "$title Test $count for $council Detail", + title => "$title Test $count for $body", + detail => "$title Test $count for $body Detail", used_map => 't', name => 'Test User', anonymous => 'f', |