Skip to content

Commit efc0747

Browse files
Merge branch '6.2' into 6.3
* 6.2: Fix merge Migrate to `static` data providers using `rector/rector`
2 parents 275d858 + aedf3cb commit efc0747

14 files changed

+31
-31
lines changed

Diff for: Tests/CssSelectorConverterTest.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ public function testCssToXPathWithoutPrefix($css, $xpath)
6060
$this->assertEquals($xpath, $converter->toXPath($css, ''), '->parse() parses an input string and returns a node');
6161
}
6262

63-
public function getCssToXPathWithoutPrefixTestData()
63+
public static function getCssToXPathWithoutPrefixTestData()
6464
{
6565
return [
6666
['h1', 'h1'],

Diff for: Tests/Node/SpecificityTest.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ public function testPlusValue(Specificity $specificity, $value)
2828
$this->assertEquals($value + 123, $specificity->plus(new Specificity(1, 2, 3))->getValue());
2929
}
3030

31-
public function getValueTestData()
31+
public static function getValueTestData()
3232
{
3333
return [
3434
[new Specificity(0, 0, 0), 0],
@@ -45,7 +45,7 @@ public function testCompareTo(Specificity $a, Specificity $b, $result)
4545
$this->assertEquals($result, $a->compareTo($b));
4646
}
4747

48-
public function getCompareTestData()
48+
public static function getCompareTestData()
4949
{
5050
return [
5151
[new Specificity(0, 0, 0), new Specificity(0, 0, 0), 0],

Diff for: Tests/Parser/Handler/AbstractHandlerTestCase.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,9 @@ public function testDontHandleValue($value)
4343
$this->assertRemainingContent($reader, $value);
4444
}
4545

46-
abstract public function getHandleValueTestData();
46+
abstract public static function getHandleValueTestData();
4747

48-
abstract public function getDontHandleValueTestData();
48+
abstract public static function getDontHandleValueTestData();
4949

5050
abstract protected function generateHandler();
5151

Diff for: Tests/Parser/Handler/CommentHandlerTest.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public function testHandleValue($value, Token $unusedArgument, $remainingContent
3030
$this->assertRemainingContent($reader, $remainingContent);
3131
}
3232

33-
public function getHandleValueTestData()
33+
public static function getHandleValueTestData()
3434
{
3535
return [
3636
// 2nd argument only exists for inherited method compatibility
@@ -39,7 +39,7 @@ public function getHandleValueTestData()
3939
];
4040
}
4141

42-
public function getDontHandleValueTestData()
42+
public static function getDontHandleValueTestData()
4343
{
4444
return [
4545
['>'],

Diff for: Tests/Parser/Handler/HashHandlerTest.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919
class HashHandlerTest extends AbstractHandlerTestCase
2020
{
21-
public function getHandleValueTestData()
21+
public static function getHandleValueTestData()
2222
{
2323
return [
2424
['#id', new Token(Token::TYPE_HASH, 'id', 0), ''],
@@ -29,7 +29,7 @@ public function getHandleValueTestData()
2929
];
3030
}
3131

32-
public function getDontHandleValueTestData()
32+
public static function getDontHandleValueTestData()
3333
{
3434
return [
3535
['id'],

Diff for: Tests/Parser/Handler/IdentifierHandlerTest.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919
class IdentifierHandlerTest extends AbstractHandlerTestCase
2020
{
21-
public function getHandleValueTestData()
21+
public static function getHandleValueTestData()
2222
{
2323
return [
2424
['foo', new Token(Token::TYPE_IDENTIFIER, 'foo', 0), ''],
@@ -29,7 +29,7 @@ public function getHandleValueTestData()
2929
];
3030
}
3131

32-
public function getDontHandleValueTestData()
32+
public static function getDontHandleValueTestData()
3333
{
3434
return [
3535
['>'],

Diff for: Tests/Parser/Handler/NumberHandlerTest.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818
class NumberHandlerTest extends AbstractHandlerTestCase
1919
{
20-
public function getHandleValueTestData()
20+
public static function getHandleValueTestData()
2121
{
2222
return [
2323
['12', new Token(Token::TYPE_NUMBER, '12', 0), ''],
@@ -30,7 +30,7 @@ public function getHandleValueTestData()
3030
];
3131
}
3232

33-
public function getDontHandleValueTestData()
33+
public static function getDontHandleValueTestData()
3434
{
3535
return [
3636
['hello'],

Diff for: Tests/Parser/Handler/StringHandlerTest.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919
class StringHandlerTest extends AbstractHandlerTestCase
2020
{
21-
public function getHandleValueTestData()
21+
public static function getHandleValueTestData()
2222
{
2323
return [
2424
['"hello"', new Token(Token::TYPE_STRING, 'hello', 1), ''],
@@ -31,7 +31,7 @@ public function getHandleValueTestData()
3131
];
3232
}
3333

34-
public function getDontHandleValueTestData()
34+
public static function getDontHandleValueTestData()
3535
{
3636
return [
3737
['hello'],

Diff for: Tests/Parser/Handler/WhitespaceHandlerTest.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
class WhitespaceHandlerTest extends AbstractHandlerTestCase
1818
{
19-
public function getHandleValueTestData()
19+
public static function getHandleValueTestData()
2020
{
2121
return [
2222
[' ', new Token(Token::TYPE_WHITESPACE, ' ', 0), ''],
@@ -28,7 +28,7 @@ public function getHandleValueTestData()
2828
];
2929
}
3030

31-
public function getDontHandleValueTestData()
31+
public static function getDontHandleValueTestData()
3232
{
3333
return [
3434
['>'],

Diff for: Tests/Parser/ParserTest.php

+6-6
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ public function testParseSeriesException($series)
9191
Parser::parseSeries($function->getArguments());
9292
}
9393

94-
public function getParserTestData()
94+
public static function getParserTestData()
9595
{
9696
return [
9797
['*', ['Element[*]']],
@@ -149,7 +149,7 @@ public function getParserTestData()
149149
];
150150
}
151151

152-
public function getParserExceptionTestData()
152+
public static function getParserExceptionTestData()
153153
{
154154
return [
155155
['attributes(href)/html/body/a', SyntaxErrorException::unexpectedToken('selector', new Token(Token::TYPE_DELIMITER, '(', 10))->getMessage()],
@@ -179,7 +179,7 @@ public function getParserExceptionTestData()
179179
];
180180
}
181181

182-
public function getPseudoElementsTestData()
182+
public static function getPseudoElementsTestData()
183183
{
184184
return [
185185
['foo', 'Element[foo]', ''],
@@ -201,7 +201,7 @@ public function getPseudoElementsTestData()
201201
];
202202
}
203203

204-
public function getSpecificityTestData()
204+
public static function getSpecificityTestData()
205205
{
206206
return [
207207
['*', 0],
@@ -229,7 +229,7 @@ public function getSpecificityTestData()
229229
];
230230
}
231231

232-
public function getParseSeriesTestData()
232+
public static function getParseSeriesTestData()
233233
{
234234
return [
235235
['1n+3', 1, 3],
@@ -251,7 +251,7 @@ public function getParseSeriesTestData()
251251
];
252252
}
253253

254-
public function getParseSeriesExceptionTestData()
254+
public static function getParseSeriesExceptionTestData()
255255
{
256256
return [
257257
['foo'],

Diff for: Tests/Parser/Shortcut/ClassParserTest.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ public function testParse($source, $representation)
3232
$this->assertEquals($representation, (string) $selector->getTree());
3333
}
3434

35-
public function getParseTestData()
35+
public static function getParseTestData()
3636
{
3737
return [
3838
['.testclass', 'Class[Element[*].testclass]'],

Diff for: Tests/Parser/Shortcut/ElementParserTest.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ public function testParse($source, $representation)
3232
$this->assertEquals($representation, (string) $selector->getTree());
3333
}
3434

35-
public function getParseTestData()
35+
public static function getParseTestData()
3636
{
3737
return [
3838
['*', 'Element[*]'],

Diff for: Tests/Parser/Shortcut/HashParserTest.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ public function testParse($source, $representation)
3232
$this->assertEquals($representation, (string) $selector->getTree());
3333
}
3434

35-
public function getParseTestData()
35+
public static function getParseTestData()
3636
{
3737
return [
3838
['#testid', 'Hash[Element[*]#testid]'],

Diff for: Tests/XPath/TranslatorTest.php

+5-5
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ public function testOnlyOfTypeFindsSingleChildrenOfGivenType()
165165
$this->assertSame('A', $nodeList->item(0)->textContent);
166166
}
167167

168-
public function getXpathLiteralTestData()
168+
public static function getXpathLiteralTestData()
169169
{
170170
return [
171171
['foo', "'foo'"],
@@ -175,7 +175,7 @@ public function getXpathLiteralTestData()
175175
];
176176
}
177177

178-
public function getCssToXPathTestData()
178+
public static function getCssToXPathTestData()
179179
{
180180
return [
181181
['*', '*'],
@@ -222,7 +222,7 @@ public function getCssToXPathTestData()
222222
];
223223
}
224224

225-
public function getXmlLangTestData()
225+
public static function getXmlLangTestData()
226226
{
227227
return [
228228
[':lang("EN")', ['first', 'second', 'third', 'fourth']],
@@ -237,7 +237,7 @@ public function getXmlLangTestData()
237237
];
238238
}
239239

240-
public function getHtmlIdsTestData()
240+
public static function getHtmlIdsTestData()
241241
{
242242
return [
243243
['div', ['outer-div', 'li-div', 'foobar-div']],
@@ -362,7 +362,7 @@ public function getHtmlIdsTestData()
362362
];
363363
}
364364

365-
public function getHtmlShakespearTestData()
365+
public static function getHtmlShakespearTestData()
366366
{
367367
return [
368368
['*', 246],

0 commit comments

Comments
 (0)