113 $this->assertCount(1, $resources, "Must found only one resources of type ore:Aggregation"); |
114 $this->assertCount(1, $resources, "Must found only one resources of type ore:Aggregation"); |
114 $this->assertEquals(CocoonTextRdfMapperTest::TEST_GRAPH_URI,$resources[0]->getUri()); |
115 $this->assertEquals(CocoonTextRdfMapperTest::TEST_GRAPH_URI,$resources[0]->getUri()); |
115 } |
116 } |
116 |
117 |
117 /** |
118 /** |
|
119 * Test providedCHO identifier. |
|
120 * |
|
121 * @return void |
|
122 */ |
|
123 public function testProvidedChoId() { |
|
124 $resources = $this->resGraphes['BASE']->allOfType('edm:ProvidedCHO'); |
|
125 |
|
126 $this->assertCount(1, $resources, "Must found only one resources of type edm:ProvidedCHO"); |
|
127 $providedCHO = $resources[0]; |
|
128 |
|
129 $identifier = $providedCHO->getLiteral('<http://purl.org/dc/terms/identifier>'); |
|
130 |
|
131 $this->assertInstanceOf('EasyRdf\Literal', $identifier, "identifier value must be a literal"); |
|
132 $this->assertEquals(CocoonTextRdfMapperTest::TEST_INPUT_ID, $identifier->getValue(), "Value must be equals to ".CocoonTextRdfMapperTest::TEST_INPUT_ID); |
|
133 |
|
134 } |
|
135 |
|
136 /** |
118 * Test providedCHO uri. |
137 * Test providedCHO uri. |
119 * |
138 * |
120 * @return void |
139 * @return void |
121 */ |
140 */ |
122 public function testProvidedChoURI() { |
141 public function testProvidedChoURI() { |
123 $resources = $this->resGraphes['BASE']->allOfType('edm:ProvidedCHO'); |
142 $resources = $this->resGraphes['BASE']->allOfType('edm:ProvidedCHO'); |
124 |
143 |
125 $this->assertCount(1, $resources, "Must found only one resources of type edm:ProvidedCHO"); |
144 $this->assertCount(1, $resources, "Must found only one resources of type edm:ProvidedCHO"); |
126 $this->assertEquals(CocoonTextRdfMapperTest::TEST_CHO_URI,$resources[0]->getUri()); |
145 $this->assertEquals(CocoonTextRdfMapperTest::TEST_CHO_URI,$resources[0]->getUri()); |
127 } |
146 } |
|
147 |
|
148 |
128 |
149 |
129 /** |
150 /** |
130 * Test that the returned graph does not have a http://purl.org/dc/dcmitype/Sound type |
151 * Test that the returned graph does not have a http://purl.org/dc/dcmitype/Sound type |
131 * |
152 * |
132 * @return void |
153 * @return void |