A lot :)
This commit is contained in:
parent
aad67af0d1
commit
63fc206c27
153 changed files with 2043 additions and 646 deletions
|
|
@ -1,37 +1,39 @@
|
|||
require 'application_system_test_case'
|
||||
# frozen_string_literal: true
|
||||
|
||||
require "application_system_test_case"
|
||||
|
||||
class ElementsTest < ApplicationSystemTestCase
|
||||
setup do
|
||||
@element = elements(:one)
|
||||
end
|
||||
|
||||
test 'visiting the index' do
|
||||
test "visiting the index" do
|
||||
visit elements_url
|
||||
assert_selector 'h1', text: 'Elemente'
|
||||
assert_selector "h1", text: "Elemente"
|
||||
end
|
||||
|
||||
test 'should create element' do
|
||||
test "should create element" do
|
||||
visit elements_url
|
||||
click_on 'Element hinzufügen'
|
||||
click_on "Element hinzufügen"
|
||||
|
||||
fill_in_rich_text_area 'Details', with: @element.description_html
|
||||
fill_in 'Pfad', with: @element.path
|
||||
fill_in 'Beschreibung', with: @element.title
|
||||
click_on 'Element erstellen'
|
||||
fill_in_rich_text_area "Details", with: @element.description_html
|
||||
fill_in "Pfad", with: @element.path
|
||||
fill_in "Beschreibung", with: @element.title
|
||||
click_on "Element erstellen"
|
||||
end
|
||||
|
||||
test 'should update Element' do
|
||||
test "should update Element" do
|
||||
visit element_url(@element)
|
||||
click_on 'Element bearbeiten', match: :first
|
||||
click_on "Element bearbeiten", match: :first
|
||||
|
||||
fill_in_rich_text_area 'Details', with: @element.description_html
|
||||
fill_in 'Pfad', with: @element.path
|
||||
fill_in 'Beschreibung', with: @element.title
|
||||
click_on 'Element aktualisieren'
|
||||
fill_in_rich_text_area "Details", with: @element.description_html
|
||||
fill_in "Pfad", with: @element.path
|
||||
fill_in "Beschreibung", with: @element.title
|
||||
click_on "Element aktualisieren"
|
||||
end
|
||||
|
||||
test 'should destroy Element' do
|
||||
test "should destroy Element" do
|
||||
visit element_url(@element)
|
||||
click_on 'Element löschen', match: :first
|
||||
click_on "Element löschen", match: :first
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue