Skip to content

Commit 1906d29

Browse files
committed
style fixes
1 parent 7c4a3af commit 1906d29

File tree

2 files changed

+9
-8
lines changed

2 files changed

+9
-8
lines changed

src/Rct567/DomQuery/DomQuery.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -991,7 +991,8 @@ function ($matches) {
991991
$expression = preg_replace_callback(
992992
'|\[([a-z0-9_-]+)\$=[\'"]([^\'"]+)[\'"]\]|i',
993993
function ($matches) {
994-
return "[@".$matches[1]." and substring(@".$matches[1].", string-length(@".$matches[1].")-".(strlen($matches[2])-1).") = '".$matches[2]."']";
994+
return "[@".$matches[1]." and substring(@".$matches[1].", string-length(@".$matches[1].")-".
995+
(strlen($matches[2])-1).") = '".$matches[2]."']";
995996
},
996997
$expression
997998
);

tests/Rct567/DomQuery/Tests/DomQuerySelectorsTest.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ public function testCssToXpath()
6060
/*
6161
* Test select by tagname selector
6262
*/
63-
public function testElementTagnameSelector()
63+
public function testElementTagnameSelector()
6464
{
6565
$dom = new DomQuery('<a>1</a><b>2</b><i>3</i>');
6666
$this->assertEquals('2', $dom->find('b')->text());
@@ -69,7 +69,7 @@ public function testElementTagnameSelector()
6969
/*
7070
* Test wildcard selector
7171
*/
72-
public function testWildcardSelector()
72+
public function testWildcardSelector()
7373
{
7474
$dom = new DomQuery('<a>1</a><b>2</b>');
7575
$this->assertEquals(2, $dom->find('*')->length);
@@ -78,7 +78,7 @@ public function testWildcardSelector()
7878
/*
7979
* Test children selector
8080
*/
81-
public function testSelectChildrenSelector()
81+
public function testSelectChildrenSelector()
8282
{
8383
$dom = new DomQuery('<div><a>1</a><b>2</b></div><a>3</a>');
8484
$this->assertEquals('1', $dom->find('div > a')->text());
@@ -88,7 +88,7 @@ public function testSelectChildrenSelector()
8888
/*
8989
* Test id selector
9090
*/
91-
public function testIdSelector()
91+
public function testIdSelector()
9292
{
9393
$dom = new DomQuery('<div><a>1</a><b>2</b></div><a id="here">3</a>');
9494
$this->assertEquals('3', $dom->find('#here')->text());
@@ -98,7 +98,7 @@ public function testIdSelector()
9898
/*
9999
* Test descendant selector
100100
*/
101-
public function testDescendantSelector()
101+
public function testDescendantSelector()
102102
{
103103
$dom = new DomQuery('<div><a>1</a><b>2</b></div><a id="here">3</a><p><a>4</a></p>');
104104
$this->assertEquals('2', $dom->find('div > b')->text());
@@ -109,7 +109,7 @@ public function testDescendantSelector()
109109
/*
110110
* Test multible selectors
111111
*/
112-
public function testMultibleSelectors()
112+
public function testMultibleSelectors()
113113
{
114114
$dom = new DomQuery('<div><a>1</a><b>2</b></div><a id="here">3</a><p><a>4</a></p>');
115115
$this->assertEquals(2, $dom->find('#here, div > b')->length);
@@ -118,7 +118,7 @@ public function testMultibleSelectors()
118118
/*
119119
*
120120
*/
121-
public function testAttributeSelector()
121+
public function testAttributeSelector()
122122
{
123123
$dom = new DomQuery('<ul>
124124
<li>list item 1</li>

0 commit comments

Comments
 (0)