Completed
Push — master ( a07cb6...94d001 )
by Kevin
02:48
created

Exists::assertSelector()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 7
Code Lines 5

Duplication

Lines 7
Ratio 100 %

Importance

Changes 1
Bugs 1 Features 0
Metric Value
c 1
b 1
f 0
dl 7
loc 7
rs 9.4285
cc 1
eloc 5
nc 1
nop 1
1
<?php
2
3
namespace Magium\Assertions\Text;
4
5
use Magium\Assertions\SelectorAssertionInterface;
6
use Magium\WebDriver\WebDriver;
7
8 View Code Duplication
class Exists extends \Magium\Assertions\Element\Exists implements SelectorAssertionInterface
0 ignored issues
show
Duplication introduced by
This class seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
9
{
10
    const ASSERTION = 'Text\Exists';
11
12
    use TextTrait;
13
14
    public function assertSelector($selector)
15
    {
16
        $selector = $this->createXpath($selector);
17
        $this->setSelector($selector);
18
        $this->setBy(WebDriver::BY_XPATH);
19
        $this->assert();
20
    }
21
22
}
23