aboutsummaryrefslogtreecommitdiffstats
path: root/spec/models/info_request_spec.rb
Commit message (Collapse)AuthorAgeLines
* Make admin edits affect info_request_event described_states.Louise Crow2013-08-15-0/+21
| | | | | | | Make sure that admin edits changing the described state of an info request are reflected in the latest_status and status values of info request events so that the info requests are retrieved correctly in status-based searches.
* Allow 'edit' and 'status_update' calculated states to propagate.Louise Crow2013-08-15-3/+29
| | | | | | | | Update test expectations and add further test to explicitly show that we want the described status from a status update to be propagated to a preceding response, as well as being filled in in the status update itself (which is mostly to deal with the case where there isn't a preceding response). Make those changes to calculate_event_states
* Merge branch 'feature/localisation-fixes' into rails-3-developLouise Crow2013-07-29-0/+1
|\
| * Add loading of raw emails - test depends on this.Louise Crow2013-07-23-0/+1
| |
* | Merge remote-tracking branch ↵Louise Crow2013-07-23-0/+203
|\ \ | |/ |/| | | | | | | | | 'openaustralia_github/tests_set_described_state' into rails-3-develop Conflicts: spec/models/info_request_spec.rb
| * How we would handle event states if we added a state_update event whenever a ↵Matthew Landauer2013-04-20-17/+41
| | | | | | | | user classifies a request
| * Access events in tests as an arrayMatthew Landauer2013-04-20-42/+43
| |
| * Test case that shows up event states bug in ↵Matthew Landauer2013-04-18-1/+18
| | | | | | | | https://www.whatdotheyknow.com/details/request/family_support_worker_redundanci
| * Test case that shows up event states bug in ↵Matthew Landauer2013-04-18-0/+20
| | | | | | | | https://www.whatdotheyknow.com/request/human_rights_and_deprivation_of
| * Testing an internal reviewMatthew Landauer2013-04-18-109/+131
| |
| * Add test for events in another situationMatthew Landauer2013-04-15-0/+28
| |
| * Check event_type in testsMatthew Landauer2013-04-15-0/+7
| |
| * Test event states when follow up message is sentMatthew Landauer2013-04-15-0/+24
| |
| * Added a commentMatthew Landauer2013-04-15-0/+2
| |
| * Test events some moreMatthew Landauer2013-04-15-5/+22
| |
| * Test event status after a response is receivedMatthew Landauer2013-04-15-12/+39
| |
| * Test to check event states after initial request is sentMatthew Landauer2013-04-15-0/+14
| |
* | Merge branch 'hotfix/0.11.0.7' into rails-3-developLouise Crow2013-06-10-24/+36
|\ \ | | | | | | | | | | | | Conflicts: spec/models/info_request_spec.rb
| * | Cope with replying to a message with a missing or empty SubjectMark Longair2013-06-07-0/+12
| |/ | | | | | | | | | | Conflicts: spec/models/info_request_spec.rb
* / Handle request for json for an external request. Closes #973.Louise Crow2013-06-07-0/+29
|/
* Merge remote-tracking branch 'mysociety/develop' into rails-3-developHenare Degan2013-03-14-2/+2
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: Gemfile Gemfile.lock app/controllers/admin_request_controller.rb app/controllers/admin_track_controller.rb app/controllers/request_controller.rb app/controllers/services_controller.rb app/helpers/link_to_helper.rb app/mailers/request_mailer.rb app/models/application_mailer.rb app/models/info_request.rb app/views/admin_censor_rule/edit.html.erb app/views/admin_censor_rule/new.html.erb app/views/admin_public_body/_form.html.erb app/views/admin_public_body/_locale_selector.html.erb app/views/admin_public_body/_one_list.html.erb app/views/admin_public_body/edit.html.erb app/views/admin_public_body/list.html.erb app/views/admin_public_body/new.html.erb app/views/admin_request/_incoming_message_actions.html.erb app/views/admin_request/edit.html.erb app/views/admin_request/edit_comment.html.erb app/views/admin_request/edit_outgoing.html.erb app/views/admin_request/list.html.erb app/views/admin_request/list_old_unclassified.html.erb app/views/admin_request/show.html.erb app/views/admin_track/_some_tracks.html.erb app/views/admin_track/list.html.erb app/views/admin_user/edit.html.erb app/views/admin_user/list.html.erb app/views/admin_user/show.html.erb app/views/general/_footer.html.erb app/views/general/exception_caught.html.erb app/views/help/contact.html.erb app/views/layouts/default.html.erb app/views/public_body/_alphabet.html.erb app/views/request/_request_listing_single.html.erb app/views/request/_sidebar.html.erb app/views/request/new.html.erb app/views/request/show.html.erb app/views/request_mailer/external_response.rhtml app/views/request_mailer/fake_response.rhtml config/environment.rb config/environments/production.rb config/routes.rb spec/controllers/admin_censor_rule_controller_spec.rb spec/controllers/request_controller_spec.rb spec/controllers/track_controller_spec.rb spec/helpers/link_to_helper_spec.rb spec/mailers/request_mailer_spec.rb spec/models/info_request_spec.rb spec/spec_helper.rb spec/views/public_body/show.html.erb_spec.rb spec/views/request/show.html.erb_spec.rb vendor/plugins/rails_xss/lib/rails_xss/erubis.rb
| * InfoRequestEvent should know about its event typesMatthew Landauer2013-03-02-2/+2
| |
* | safe_mock_model doesn't seem to be needed, also tested in Ruby 1.9Henare Degan2012-12-12-8/+8
|/
* Standardize slug generation for external users so that it uses the same ↵Louise Crow2012-11-29-0/+16
| | | | underlying method as other slug generation. Fixes #567.
* use safe_mock_modelJames McKinney2012-11-01-6/+6
|
* Allow InfoRequest.find_old_unclassified to accept an offset param so it can ↵Louise Crow2012-09-13-0/+8
| | | | be used in conjunction with pagination.
* Add some more efficient methods for getting old unclassified request counts, ↵Louise Crow2012-09-11-11/+40
| | | | and random sets of small numbers of old unclassified requests.
* Merge branch 'release/0.6.3' into developLouise Crow2012-08-22-19/+81
|\ | | | | | | | | | | | | | | Conflicts: app/controllers/admin_public_body_controller.rb app/views/admin_public_body/import_csv.rhtml spec/controllers/admin_public_body_controller_spec.rb spec/models/info_request_spec.rb
| * Apply global and public body censor rules to binary files.Louise Crow2012-08-14-23/+60
| |
| * Add association between public bodies and censor rules, have info_request ↵Louise Crow2012-08-14-0/+8
| | | | | | | | apply rules from its public body.
| * Add concept of global censor rules as orthogonal to regex censor rules. ↵Louise Crow2012-08-14-117/+135
| | | | | | | | Apply global rules to every request, not regex rules.
* | Fix testsRobin Houston2012-08-20-3/+3
| | | | | | | | | | | | | | | | | | Also make the InfoRequest#is_old_unclassified? method a little more conservative, by returning false only is the is_external? method returns true. This makes it subtly inconsistent with InfoRequest.find_old_unclassified, but it is better I think to be subtly inconsistent than to risk breaking things that used to work.
* | Merge branch 'wdtk' into developLouise Crow2012-08-16-98/+127
|\ \ | |/ |/| | | | | | | | | Conflicts: app/controllers/admin_request_controller.rb config/httpd.conf spec/models/info_request_spec.rb
| * Add method all_can_view? which can be used to determine whether it is ok to ↵Louise Crow2012-08-16-99/+128
| | | | | | | | cache the associated objects for an info request in the file cache which will be served up without authentication.
* | Misc fixes to get tests to pass - notably a MonkeyPatch to work around ↵Seb Bacon2012-07-13-0/+1
| | | | | | | | problem testing template results
* | Support regular expressions in CensorRules; also support 'global' ↵Seb Bacon2012-07-13-1/+20
|/ | | | CensorRules that aren't attached to a User or Request or Public Body (but don't expose this in the admin UI). Fixes #33
* Load all fixtures for all testsRobin Houston2012-01-31-7/+0
| | | | | | | | | The ad hoc specification of fixtures has been an ongoing source of bugs in the tests. The straw that broke the camel’s back is that 7c6eb09 requires the fixtures to be loaded in order (i.e. children before their parents), and it would have been a painful process to reorder all the dozens of different fixture lists, but the test system ought to be more reliable this way.
* Load all raw emails for testingRobin Houston2012-01-29-1/+1
| | | | | | | | | | | Previously there was just one raw email, and the test code relied on that fact. Generalise it to handle multiple raw emails. This change causes a number of tests to fail, because it exposes failures that should have happened when the second raw email was added but were masked by the fact that the text of this second raw email was never loaded. These failures will be fixed in the next commit.
* Further improvements to attachment cachingSeb Bacon2011-12-13-1/+1
|
* Merge remote-tracking branch 'jpmckinney/pre1.9' into developSeb Bacon2011-11-24-2/+2
|\ | | | | | | | | Conflicts: spec/controllers/request_controller_spec.rb
| * add safe_mock_model to safely handle #to_ary calls in 1.9James McKinney2011-10-17-2/+2
| |
* | allow specs to run independentlyJames McKinney2011-10-16-5/+5
|/
* fix fixtures order to avoid postgresql foreign key errorsJames McKinney2011-10-11-4/+4
|
* Fix up missing fixtures (causing failures dependent on order the tests were ↵Seb Bacon2011-08-10-1/+1
| | | | funr). Also tidy up raw_email setup code to match everywhere.
* Guess holding pen emails based on having a correct hash and an incorrect id. ↵Seb Bacon2011-08-08-0/+34
| | | | Closes #117
* added missing outgoing_messages fixture to testDavid Cabo2011-07-23-1/+1
|
* test with state other than "requires_admin" (as that state sends emails and ↵Seb Bacon2011-07-13-1/+1
| | | | breaks other tests :()
* Refactor custom states loading (use class methods where appropriate, ↵Seb Bacon2011-07-12-1/+2
| | | | simplify main code at the cost (small) of test legibility)
* ensure we don't load custom states from plugins when running testsSeb Bacon2011-07-12-1/+1
|
* Improve factoring out of custom states code (refactor a little, add tests)Seb Bacon2011-07-12-0/+36
|