Replace link with button in Proposal created
This commit is contained in:
@@ -13,9 +13,9 @@
|
|||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<% if can?(:publish, @proposal) %>
|
<% if can?(:publish, @proposal) %>
|
||||||
<%= link_to t("proposals.created.publish"),
|
<%= button_to t("proposals.created.publish"),
|
||||||
publish_proposal_path(@proposal),
|
publish_proposal_path(@proposal),
|
||||||
method: :patch, class: "button" %>
|
method: :patch, class: "button", form_class: "inline" %>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -53,7 +53,7 @@ describe "Multitenancy", :seed_tenants do
|
|||||||
|
|
||||||
expect(page).to have_content "Proposal created successfully."
|
expect(page).to have_content "Proposal created successfully."
|
||||||
|
|
||||||
click_link "No, I want to publish the proposal"
|
click_button "No, I want to publish the proposal"
|
||||||
|
|
||||||
expect(page).to have_content "You've created a proposal!"
|
expect(page).to have_content "You've created a proposal!"
|
||||||
|
|
||||||
|
|||||||
@@ -356,7 +356,7 @@ describe "Proposals" do
|
|||||||
expect(page).to have_content "Help refugees"
|
expect(page).to have_content "Help refugees"
|
||||||
expect(page).not_to have_content "You can also see more information about improving your campaign"
|
expect(page).not_to have_content "You can also see more information about improving your campaign"
|
||||||
|
|
||||||
click_link "No, I want to publish the proposal"
|
click_button "No, I want to publish the proposal"
|
||||||
|
|
||||||
expect(page).to have_content "Improve your campaign and get more support"
|
expect(page).to have_content "Improve your campaign and get more support"
|
||||||
click_link "Not now, go to my proposal"
|
click_link "Not now, go to my proposal"
|
||||||
@@ -424,7 +424,7 @@ describe "Proposals" do
|
|||||||
click_button "Create proposal"
|
click_button "Create proposal"
|
||||||
|
|
||||||
expect(page).to have_content "Proposal created successfully."
|
expect(page).to have_content "Proposal created successfully."
|
||||||
click_link "No, I want to publish the proposal"
|
click_button "No, I want to publish the proposal"
|
||||||
click_link "Not now, go to my proposal"
|
click_link "Not now, go to my proposal"
|
||||||
|
|
||||||
click_link "Dashboard"
|
click_link "Dashboard"
|
||||||
@@ -450,7 +450,7 @@ describe "Proposals" do
|
|||||||
|
|
||||||
click_button "Create proposal"
|
click_button "Create proposal"
|
||||||
expect(page).to have_content "Proposal created successfully."
|
expect(page).to have_content "Proposal created successfully."
|
||||||
click_link "No, I want to publish the proposal"
|
click_button "No, I want to publish the proposal"
|
||||||
click_link "Not now, go to my proposal"
|
click_link "Not now, go to my proposal"
|
||||||
|
|
||||||
expect(page).to have_css "h1", exact_text: "Help refugees"
|
expect(page).to have_css "h1", exact_text: "Help refugees"
|
||||||
@@ -481,7 +481,7 @@ describe "Proposals" do
|
|||||||
click_button "Create proposal"
|
click_button "Create proposal"
|
||||||
|
|
||||||
expect(page).to have_content "Proposal created successfully."
|
expect(page).to have_content "Proposal created successfully."
|
||||||
click_link "No, I want to publish the proposal"
|
click_button "No, I want to publish the proposal"
|
||||||
click_link "Not now, go to my proposal"
|
click_link "Not now, go to my proposal"
|
||||||
|
|
||||||
expect(page).to have_content "Testing an attack"
|
expect(page).to have_content "Testing an attack"
|
||||||
@@ -504,7 +504,7 @@ describe "Proposals" do
|
|||||||
click_button "Create proposal"
|
click_button "Create proposal"
|
||||||
|
|
||||||
expect(page).to have_content "Proposal created successfully."
|
expect(page).to have_content "Proposal created successfully."
|
||||||
click_link "No, I want to publish the proposal"
|
click_button "No, I want to publish the proposal"
|
||||||
click_link "Not now, go to my proposal"
|
click_link "Not now, go to my proposal"
|
||||||
|
|
||||||
expect(page).to have_content "Testing auto link"
|
expect(page).to have_content "Testing auto link"
|
||||||
@@ -528,7 +528,7 @@ describe "Proposals" do
|
|||||||
click_button "Create proposal"
|
click_button "Create proposal"
|
||||||
|
|
||||||
expect(page).to have_content "Proposal created successfully."
|
expect(page).to have_content "Proposal created successfully."
|
||||||
click_link "No, I want to publish the proposal"
|
click_button "No, I want to publish the proposal"
|
||||||
click_link "Not now, go to my proposal"
|
click_link "Not now, go to my proposal"
|
||||||
|
|
||||||
expect(page).to have_content "Testing auto link"
|
expect(page).to have_content "Testing auto link"
|
||||||
@@ -568,7 +568,7 @@ describe "Proposals" do
|
|||||||
click_button "Create proposal"
|
click_button "Create proposal"
|
||||||
|
|
||||||
expect(page).to have_content "Proposal created successfully."
|
expect(page).to have_content "Proposal created successfully."
|
||||||
click_link "No, I want to publish the proposal"
|
click_button "No, I want to publish the proposal"
|
||||||
click_link "Not now, go to my proposal"
|
click_link "Not now, go to my proposal"
|
||||||
|
|
||||||
within "#geozone" do
|
within "#geozone" do
|
||||||
@@ -613,7 +613,7 @@ describe "Proposals" do
|
|||||||
click_button "Create proposal"
|
click_button "Create proposal"
|
||||||
|
|
||||||
expect(page).to have_content "Proposal created successfully."
|
expect(page).to have_content "Proposal created successfully."
|
||||||
click_link "No, I want to publish the proposal"
|
click_button "No, I want to publish the proposal"
|
||||||
click_link "Not now, go to my proposal"
|
click_link "Not now, go to my proposal"
|
||||||
|
|
||||||
within "#geozone" do
|
within "#geozone" do
|
||||||
|
|||||||
@@ -74,7 +74,7 @@ describe "Tags" do
|
|||||||
click_button "Create proposal"
|
click_button "Create proposal"
|
||||||
|
|
||||||
expect(page).to have_content "Proposal created successfully."
|
expect(page).to have_content "Proposal created successfully."
|
||||||
click_link "No, I want to publish the proposal"
|
click_button "No, I want to publish the proposal"
|
||||||
click_link "Not now, go to my proposal"
|
click_link "Not now, go to my proposal"
|
||||||
|
|
||||||
expect(page).to have_content "Economía"
|
expect(page).to have_content "Economía"
|
||||||
@@ -99,7 +99,7 @@ describe "Tags" do
|
|||||||
click_button "Create proposal"
|
click_button "Create proposal"
|
||||||
|
|
||||||
expect(page).to have_content "Proposal created successfully."
|
expect(page).to have_content "Proposal created successfully."
|
||||||
click_link "No, I want to publish the proposal"
|
click_button "No, I want to publish the proposal"
|
||||||
click_link "Not now, go to my proposal"
|
click_link "Not now, go to my proposal"
|
||||||
|
|
||||||
expect(page).to have_css "h1", exact_text: "Help refugees"
|
expect(page).to have_css "h1", exact_text: "Help refugees"
|
||||||
@@ -144,7 +144,7 @@ describe "Tags" do
|
|||||||
click_button "Create proposal"
|
click_button "Create proposal"
|
||||||
|
|
||||||
expect(page).to have_content "Proposal created successfully."
|
expect(page).to have_content "Proposal created successfully."
|
||||||
click_link "No, I want to publish the proposal"
|
click_button "No, I want to publish the proposal"
|
||||||
click_link "Not now, go to my proposal"
|
click_link "Not now, go to my proposal"
|
||||||
|
|
||||||
expect(page).to have_content "user_id1"
|
expect(page).to have_content "user_id1"
|
||||||
|
|||||||
Reference in New Issue
Block a user