11<?php
22declare (strict_types=1 );
33
4- namespace Tests \ Atl \ Http \ Parser ;
4+ namespace Xparse \ CssExpressionTranslator \ Test ;
55
6+ use InvalidArgumentException ;
67use PHPUnit \Framework \TestCase ;
78use Xparse \CssExpressionTranslator \CssOrXpathExpressionTranslator ;
89
@@ -13,7 +14,7 @@ final class CssOrXpathExpressionTranslatorTest extends TestCase
1314{
1415
1516 /**
16- * @return array
17+ * @return string[][]
1718 */
1819 public function getQueriesDataProvider (): array
1920 {
@@ -97,26 +98,20 @@ public function testQueries(string $input, string $expect): void
9798 {
9899 $ output = CssOrXpathExpressionTranslator::getTranslator ()
99100 ->convertToXpath ($ input );
100- static ::assertEquals ($ expect , $ output );
101+ self ::assertEquals ($ expect , $ output );
101102 }
102103
103104
104- /**
105- * @expectedException \InvalidArgumentException
106- */
107105 public function testEmptyString (): void
108106 {
109- /** @noinspection UnusedFunctionResultInspection */
107+ self :: expectException (InvalidArgumentException::class);
110108 CssOrXpathExpressionTranslator::getTranslator ()->convertToXpath ('' );
111109 }
112110
113111
114- /**
115- * @expectedException \InvalidArgumentException
116- */
117112 public function testEmptyStringWithSpaces (): void
118113 {
119- /** @noinspection UnusedFunctionResultInspection */
114+ self :: expectException (InvalidArgumentException::class);
120115 CssOrXpathExpressionTranslator::getTranslator ()->convertToXpath (' ' );
121116 }
122117
0 commit comments