diff options
Diffstat (limited to 'spec/controllers')
-rw-r--r-- | spec/controllers/admin_public_body_controller_spec.rb | 7 | ||||
-rw-r--r-- | spec/controllers/services_controller_spec.rb | 14 |
2 files changed, 19 insertions, 2 deletions
diff --git a/spec/controllers/admin_public_body_controller_spec.rb b/spec/controllers/admin_public_body_controller_spec.rb index 55a6649b2..6d6e7c1ba 100644 --- a/spec/controllers/admin_public_body_controller_spec.rb +++ b/spec/controllers/admin_public_body_controller_spec.rb @@ -70,6 +70,13 @@ describe AdminPublicBodyController, "when administering public bodies" do response.should redirect_to(:action=>'list') PublicBody.find_by_tag("department").count.should == n end + + describe 'import_csv' do + it 'should get the page successfully' do + get :import_csv + response.should be_success + end + end end describe AdminPublicBodyController, "when administering public bodies and paying attention to authentication" do diff --git a/spec/controllers/services_controller_spec.rb b/spec/controllers/services_controller_spec.rb index 2be382258..a701ae247 100644 --- a/spec/controllers/services_controller_spec.rb +++ b/spec/controllers/services_controller_spec.rb @@ -2,8 +2,15 @@ require File.expand_path(File.dirname(__FILE__) + '/../spec_helper') describe ServicesController, "when using web services" do + integrate_views - + + # store and restore the locale in the context of the test suite to isolate + # changes made in these tests + before do + @old_locale = FastGettext.locale() + end + it "should show no alaveteli message when in the deployed country" do config = MySociety::Config.load_default() config['ISO_COUNTRY_CODE'] = "DE" @@ -29,5 +36,8 @@ describe ServicesController, "when using web services" do response.body.should match(/Puede hacer solicitudes de información en España/) end + after do + FastGettext.set_locale(@old_locale) + end -end +end
\ No newline at end of file |