Created
October 4, 2011 12:58
-
-
Save daveworth/1261584 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#defines login_as | |
require File.expand_path(File.dirname(__FILE__) + '/acceptance_helper') | |
describe "MC Integration" do | |
describe "setup modal" do | |
# would want a | |
# before(:each) do | |
# login_as(:owner) | |
# visit root_path | |
# click_link "toggleMenu" | |
# click_link "MailChimp Setup" | |
# end | |
# | |
# and | |
# | |
# after(:each) do | |
# logout | |
# end | |
it "opens after menu click" do | |
login_as(:owner) do | |
visit root_path | |
click_link "toggleMenu" | |
click_link "MailChimp Setup" | |
page.should have_content("MailChimp is an email marketing service for small businesses") | |
end | |
end | |
it "closes after clicking cancel" do | |
login_as(:owner) do | |
visit root_path | |
click_link "toggleMenu" | |
click_link "MailChimp Setup" | |
find("form#mailchimpForm ul.saveCancel a#cancelButton").click | |
page.should have_no_content("MailChimp is an email marketing service for small businesses") | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment