Code Duplication    Length = 7-7 lines in 3 locations

src/Context/BrowserContext.php 3 locations

@@ 235-241 (lines=7) @@
232
    /**
233
     * @Then /^(?:|I )should see (?P<count>\d+) "(?P<element>[^"]*)" in the (?P<index>\d+)(?:st|nd|rd|th) "(?P<parent>[^"]*)"$/
234
     */
235
    public function iShouldSeeNElementInTheNthParent($count, $element, $index, $parent)
236
    {
237
        $actual = $this->countElements($element, $index, $parent);
238
        if ($actual !== $count) {
239
            throw new \Exception("$actual occurrences of the '$element' element in '$parent' found");
240
        }
241
    }
242
243
    /**
244
     * @Then (I )should see less than :count :element in the :index :parent
@@ 246-252 (lines=7) @@
243
    /**
244
     * @Then (I )should see less than :count :element in the :index :parent
245
     */
246
    public function iShouldSeeLessThanNElementInTheNthParent($count, $element, $index, $parent)
247
    {
248
        $actual = $this->countElements($element, $index, $parent);
249
        if ($actual > $count) {
250
            throw new \Exception("$actual occurrences of the '$element' element in '$parent' found");
251
        }
252
    }
253
254
    /**
255
     * @Then (I )should see more than :count :element in the :index :parent
@@ 257-263 (lines=7) @@
254
    /**
255
     * @Then (I )should see more than :count :element in the :index :parent
256
     */
257
    public function iShouldSeeMoreThanNElementInTheNthParent($count, $element, $index, $parent)
258
    {
259
        $actual = $this->countElements($element, $index, $parent);
260
        if ($actual < $count) {
261
            throw new \Exception("$actual occurrences of the '$element' element in '$parent' found");
262
        }
263
    }
264
265
    /**
266
     * Checks, that element with given CSS is enabled