equal
deleted
inserted
replaced
239 $this->assertEquals("dc:IMT",$mimetype->getDatatype()); |
239 $this->assertEquals("dc:IMT",$mimetype->getDatatype()); |
240 } |
240 } |
241 } |
241 } |
242 |
242 |
243 /** |
243 /** |
244 * Test that the web resources |
244 * Test that the web resources has good date |
245 * |
245 * |
246 * @return void |
246 * @return void |
247 */ |
247 */ |
248 public function testWebResourcesDate() { |
248 public function testWebResourcesDate() { |
249 |
249 |
263 } |
263 } |
264 |
264 |
265 } |
265 } |
266 |
266 |
267 |
267 |
|
268 /** |
|
269 * Test that the web resources as conformsTo property |
|
270 * |
|
271 * @return void |
|
272 */ |
|
273 public function testWebResourcesConformsTo() { |
|
274 |
|
275 $resources = $this->resGraphes['BASE']->allOfType('edm:WebResource'); |
|
276 foreach ($resources as $wres) { |
|
277 |
|
278 $mimetypes = $wres->all($this->resGraphes['BASE']->resource('http://purl.org/dc/elements/1.1/format')); |
|
279 $mimetype = $mimetypes[0]->getValue(); |
|
280 if($mimetype !== 'application/xml') { |
|
281 continue; |
|
282 } |
|
283 $conformsTo = $wres->get('<http://purl.org/dc/terms/conformsTo>'); |
|
284 $this->assertNotNull($conformsTo, "Must have a conformsTo node"); |
|
285 $this->assertInstanceOf('EasyRdf\Resource', $conformsTo, "Must be a resource"); |
|
286 $this->assertEquals("http://purl.org/poi/crdo.vjf.cnrs.fr/crdo-dtd_archive", $conformsTo->getUri(), "Must be http://purl.org/poi/crdo.vjf.cnrs.fr/crdo-dtd_archive"); |
|
287 } |
|
288 } |
|
289 |
|
290 |
268 } |
291 } |