diff --git a/.travis.yml b/.travis.yml index 9a5e5c4..ff06c7f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,16 +1,31 @@ language: php -php: - - 5.3 - - 5.4 - - 5.5 - - 5.6 - - 7 - - hhvm +env: + - THENEEDFORTHIS=FAIL + +matrix: + fast_finish: true + include: + - env: DM=~6.0 + php: 5.3 + - env: DM=~5.0 + php: 5.4 + - env: DM=~4.2 + php: 5.5 + - env: DM=~4.2 + php: 5.6 + - env: DM=~4.2 + php: 7 + - env: DM=~4.2 + php: hhvm + exclude: + - env: THENEEDFORTHIS=FAIL + allow_failures: + - env: DM=@dev sudo: false -install: travis_retry composer install --prefer-source +install: travis_retry composer require "wikibase/data-model=$DM" --prefer-source script: composer ci diff --git a/tests/unit/Deserializers/LegacyItemDeserializerTest.php b/tests/unit/Deserializers/LegacyItemDeserializerTest.php index 836c7f6..856fc66 100644 --- a/tests/unit/Deserializers/LegacyItemDeserializerTest.php +++ b/tests/unit/Deserializers/LegacyItemDeserializerTest.php @@ -174,7 +174,7 @@ public function testGivenStatementWithLegacyKey_itemHasStatement() { public function testGivenLabels_getLabelsReturnsThem( array $labels ) { $item = $this->itemFromSerialization( array( 'label' => $labels ) ); - $this->assertEquals( $labels, $item->getLabels()->toTextArray() ); + $this->assertEquals( $labels, $item->getFingerprint()->getLabels()->toTextArray() ); } public function TermListProvider() { @@ -199,7 +199,7 @@ public function testGivenInvalidLabels_exceptionIsThrown() { public function testGivenDescriptions_getDescriptionsReturnsThem( array $descriptions ) { $item = $this->itemFromSerialization( array( 'description' => $descriptions ) ); - $this->assertEquals( $descriptions, $item->getDescriptions()->toTextArray() ); + $this->assertEquals( $descriptions, $item->getFingerprint()->getDescriptions()->toTextArray() ); } public function testGivenInvalidAliases_exceptionIsThrown() { @@ -213,7 +213,7 @@ public function testGivenInvalidAliases_exceptionIsThrown() { public function testGivenAliases_getAliasesReturnsThem( array $aliases ) { $item = $this->itemFromSerialization( array( 'aliases' => $aliases ) ); - $this->assertEquals( $aliases, $item->getAliasGroups()->toTextArray() ); + $this->assertEquals( $aliases, $item->getFingerprint()->getAliasGroups()->toTextArray() ); } public function aliasesListProvider() { diff --git a/tests/unit/Deserializers/LegacyPropertyDeserializerTest.php b/tests/unit/Deserializers/LegacyPropertyDeserializerTest.php index 332249b..b2e26fb 100644 --- a/tests/unit/Deserializers/LegacyPropertyDeserializerTest.php +++ b/tests/unit/Deserializers/LegacyPropertyDeserializerTest.php @@ -94,7 +94,7 @@ public function testGivenLabels_getLabelsReturnsThem( array $labels ) { 'label' => $labels ) ); - $this->assertEquals( $labels, $property->getLabels()->toTextArray() ); + $this->assertEquals( $labels, $property->getFingerprint()->getLabels()->toTextArray() ); } public function TermListProvider() { @@ -123,7 +123,7 @@ public function testGivenDescriptions_getDescriptionsReturnsThem( array $descrip 'description' => $descriptions ) ); - $this->assertEquals( $descriptions, $property->getDescriptions()->toTextArray() ); + $this->assertEquals( $descriptions, $property->getFingerprint()->getDescriptions()->toTextArray() ); } public function testGivenInvalidAliases_exceptionIsThrown() { @@ -141,7 +141,7 @@ public function testGivenAliases_getAliasesReturnsThem( array $aliases ) { 'aliases' => $aliases ) ); - $this->assertEquals( $aliases, $property->getAliasGroups()->toTextArray() ); + $this->assertEquals( $aliases, $property->getFingerprint()->getAliasGroups()->toTextArray() ); } public function aliasesListProvider() {