diff --git a/src/EntityId/SuffixEntityIdParser.php b/src/EntityId/PrefixedEntityIdParser.php similarity index 96% rename from src/EntityId/SuffixEntityIdParser.php rename to src/EntityId/PrefixedEntityIdParser.php index 7d624b54..80623b2f 100644 --- a/src/EntityId/SuffixEntityIdParser.php +++ b/src/EntityId/PrefixedEntityIdParser.php @@ -15,7 +15,7 @@ * @license GPL-2.0+ * @author Daniel Kinzler */ -class SuffixEntityIdParser implements EntityIdParser { +class PrefixedEntityIdParser implements EntityIdParser { /** * @var string diff --git a/tests/unit/EntityId/SuffixEntityIdParserTest.php b/tests/unit/EntityId/PrefixedEntityIdParserTest.php similarity index 83% rename from tests/unit/EntityId/SuffixEntityIdParserTest.php rename to tests/unit/EntityId/PrefixedEntityIdParserTest.php index 3fe6d3cf..77fab88d 100644 --- a/tests/unit/EntityId/SuffixEntityIdParserTest.php +++ b/tests/unit/EntityId/PrefixedEntityIdParserTest.php @@ -5,15 +5,15 @@ use Wikibase\DataModel\Entity\BasicEntityIdParser; use Wikibase\DataModel\Entity\ItemId; use Wikibase\DataModel\Entity\PropertyId; -use Wikibase\DataModel\Services\EntityId\SuffixEntityIdParser; +use Wikibase\DataModel\Services\EntityId\PrefixedEntityIdParser; /** - * @covers Wikibase\DataModel\Services\EntityId\SuffixEntityIdParser + * @covers Wikibase\DataModel\Services\EntityId\PrefixedEntityIdParser * * @license GPL-2.0+ * @author Daniel Kinzler */ -class SuffixEntityIdParserTest extends \PHPUnit_Framework_TestCase { +class PrefixedEntityIdParserTest extends \PHPUnit_Framework_TestCase { public function validInputProvider() { return array( @@ -26,7 +26,7 @@ public function validInputProvider() { * @dataProvider validInputProvider */ public function testParse( $prefix, $input, $expected ) { - $parser = new SuffixEntityIdParser( $prefix, new BasicEntityIdParser() ); + $parser = new PrefixedEntityIdParser( $prefix, new BasicEntityIdParser() ); $this->assertEquals( $expected, $parser->parse( $input ) ); } @@ -47,7 +47,7 @@ public function invalidInputProvider() { * @dataProvider invalidInputProvider */ public function testParse_invalid( $prefix, $input ) { - $parser = new SuffixEntityIdParser( $prefix, new BasicEntityIdParser() ); + $parser = new PrefixedEntityIdParser( $prefix, new BasicEntityIdParser() ); $this->setExpectedException( 'Wikibase\DataModel\Entity\EntityIdParsingException' ); $parser->parse( $input );