@@ 90-100 (lines=11) @@ | ||
87 | * @Then the route :name should appear in the store |
|
88 | * @Then I should see the route :name in the list |
|
89 | */ |
|
90 | public function theRouteShouldAppearInTheStore($name) |
|
91 | { |
|
92 | if (!$this->indexPage->isOpen()) { |
|
93 | $this->indexPage->open(); |
|
94 | } |
|
95 | ||
96 | Assert::true( |
|
97 | $this->indexPage->isSingleResourceOnPage(['name' => $name]), |
|
98 | sprintf('Could not find route with name "%s"!', $name) |
|
99 | ); |
|
100 | } |
|
101 | ||
102 | /** |
|
103 | * @Then I should see :amount routes in the list |
|
@@ 188-198 (lines=11) @@ | ||
185 | /** |
|
186 | * @Then the route with content :title should not be added |
|
187 | */ |
|
188 | public function theRouteWithContentShouldNotBeAdded($title) |
|
189 | { |
|
190 | if (!$this->indexPage->isOpen()) { |
|
191 | $this->indexPage->open(); |
|
192 | } |
|
193 | ||
194 | Assert::false( |
|
195 | $this->indexPage->isSingleResourceOnPage(['content' => $title]), |
|
196 | sprintf('Found route with content "%s" assigned, but expected not to.', $title) |
|
197 | ); |
|
198 | } |
|
199 | } |
|
200 |
@@ 109-116 (lines=8) @@ | ||
106 | * @Then the static content :title should appear in the store |
|
107 | * @Then I should see the static content :title in the list |
|
108 | */ |
|
109 | public function theStaticContentShouldAppearInTheStore($title) |
|
110 | { |
|
111 | if (!$this->indexPage->isOpen()) { |
|
112 | $this->indexPage->open(); |
|
113 | } |
|
114 | ||
115 | Assert::true($this->indexPage->isSingleResourceOnPage(['title' => $title])); |
|
116 | } |
|
117 | ||
118 | /** |
|
119 | * @Then I should see :amount static contents in the list |
|
@@ 133-140 (lines=8) @@ | ||
130 | /** |
|
131 | * @Then the static content :title should not be added |
|
132 | */ |
|
133 | public function theStaticContentShouldNotBeAdded($title) |
|
134 | { |
|
135 | if (!$this->indexPage->isOpen()) { |
|
136 | $this->indexPage->open(); |
|
137 | } |
|
138 | ||
139 | Assert::false($this->indexPage->isSingleResourceOnPage(['title' => $title])); |
|
140 | } |
|
141 | ||
142 | /** |
|
143 | * @Given /^I want to edit (this static content)$/ |
@@ 101-111 (lines=11) @@ | ||
98 | * @Then the string block :name should appear in the store |
|
99 | * @Then I should see the string block :name in the list |
|
100 | */ |
|
101 | public function theStringBlockShouldAppearInTheStore($name) |
|
102 | { |
|
103 | if (!$this->indexPage->isOpen()) { |
|
104 | $this->indexPage->open(); |
|
105 | } |
|
106 | ||
107 | Assert::true( |
|
108 | $this->indexPage->isSingleResourceOnPage(['name' => $name]), |
|
109 | sprintf('Could not find string block with name "%s"!', $name) |
|
110 | ); |
|
111 | } |
|
112 | ||
113 | /** |
|
114 | * @Then I should see :amount string blocks in the list |
|
@@ 128-138 (lines=11) @@ | ||
125 | /** |
|
126 | * @Then the string block :name should not be added |
|
127 | */ |
|
128 | public function theStringBlockShouldNotBeAdded($name) |
|
129 | { |
|
130 | if (!$this->indexPage->isOpen()) { |
|
131 | $this->indexPage->open(); |
|
132 | } |
|
133 | ||
134 | Assert::false( |
|
135 | $this->indexPage->isSingleResourceOnPage(['name' => $name]), |
|
136 | sprintf('Static content with name %s was created, but it should not.', $name) |
|
137 | ); |
|
138 | } |
|
139 | ||
140 | /** |
|
141 | * @Given /^I want to edit (this string block)$/ |