Code Duplication    Length = 7-7 lines in 3 locations

src/Context/BrowserContext.php 3 locations

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