2022-12-08 16:16:29 +01:00
|
|
|
require 'rails_helper'
|
|
|
|
|
|
|
|
RSpec.feature "Pages", type: :feature do
|
|
|
|
describe "GET /pages" do
|
|
|
|
it "returns http success" do
|
|
|
|
visit "/merged/pages"
|
2022-12-13 18:16:11 +01:00
|
|
|
expect(page).to have_title("Dummy")
|
2022-12-08 16:16:29 +01:00
|
|
|
expect(page).to have_text("Pages")
|
|
|
|
end
|
2022-12-16 15:50:56 +01:00
|
|
|
|
|
|
|
it "has an index page" do
|
2022-12-08 16:16:29 +01:00
|
|
|
visit "/merged/pages"
|
|
|
|
click_on ("index")
|
|
|
|
end
|
2022-12-16 15:50:56 +01:00
|
|
|
|
|
|
|
it "edit page works " do
|
|
|
|
visit "/merged/pages"
|
|
|
|
within("#index") do
|
|
|
|
click_on ("Edit")
|
|
|
|
end
|
|
|
|
end
|
2022-12-08 16:16:29 +01:00
|
|
|
end
|
|
|
|
end
|