From 21b19db5a30fcb6db83f4ac9302cc94c6320a0db Mon Sep 17 00:00:00 2001 From: Jamie Winsor Date: Mon, 1 Aug 2011 11:27:28 -0700 Subject: refactor engine testing scenario Engine is now tested standalone by leveraging a dummy rails app Enable Guard for speedy testing Move factories to the more standard location `spec/factories/*` Update README with a Testing section Rename migrations to contain datetimestamps for their version to fix migration order issues when migrating the dummy application --- spec/requests/manage_blog_posts_spec.rb | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'spec/requests/manage_blog_posts_spec.rb') diff --git a/spec/requests/manage_blog_posts_spec.rb b/spec/requests/manage_blog_posts_spec.rb index 724cc59..8b1097d 100644 --- a/spec/requests/manage_blog_posts_spec.rb +++ b/spec/requests/manage_blog_posts_spec.rb @@ -1,7 +1,14 @@ require "spec_helper" describe "manage blog posts" do - login_refinery_user + # TODO: share this with other request specs + before(:each) do + user = Factory.create(:refinery_user) + visit new_refinery_user_session_url + fill_in "Login", :with => user.username + fill_in "Password", :with => user.password + click_button "Sign in" + end let!(:blog_post) { Factory(:blog_post, :title => "Refinery CMS blog post") } -- cgit v1.2.3