From a8f925a87075c8cc36d3ed29f7f64f51bc820b1e Mon Sep 17 00:00:00 2001 From: Louise Crow Date: Tue, 30 Apr 2013 16:09:10 +0100 Subject: Remove debian-specific require clause and use Gemfile to specify non-standard require - bundler should be supplying the gem now. --- spec/controllers/general_controller_spec.rb | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'spec/controllers/general_controller_spec.rb') diff --git a/spec/controllers/general_controller_spec.rb b/spec/controllers/general_controller_spec.rb index 9a88dbc3a..4a1c8b134 100644 --- a/spec/controllers/general_controller_spec.rb +++ b/spec/controllers/general_controller_spec.rb @@ -19,8 +19,11 @@ end describe GeneralController, 'when getting the blog feed' do - it 'should add a lang param correctly to a url with no querystring' do + before do AlaveteliConfiguration.stub!(:blog_feed).and_return("http://blog.example.com") + end + + it 'should add a lang param correctly to a url with no querystring' do get :blog assigns[:feed_url].should == "http://blog.example.com?lang=en" end @@ -31,6 +34,12 @@ describe GeneralController, 'when getting the blog feed' do assigns[:feed_url].should == "http://blog.example.com?alt=rss&lang=en" end + it 'should parse an item from an example feed' do + controller.stub!(:quietly_try_to_open).and_return(load_file_fixture("blog_feed.atom")) + get :blog + assigns[:blog_items].count.should == 1 + end + end describe GeneralController, "when showing the frontpage" do -- cgit v1.2.3