annotate vendor/phar-io/manifest/tests/xml/ComponentElementCollectionTest.php @ 5:12f9dff5fda9 tip

Update to Drupal core 8.7.1
author Chris Cannam
date Thu, 09 May 2019 15:34:47 +0100
parents 5311817fb629
children
rev   line source
Chris@2 1 <?php
Chris@2 2
Chris@2 3 namespace PharIo\Manifest;
Chris@2 4
Chris@2 5 use DOMDocument;
Chris@2 6
Chris@2 7 class ComponentElementCollectionTest extends \PHPUnit_Framework_TestCase {
Chris@2 8 public function testComponentElementCanBeRetrievedFromCollection() {
Chris@2 9 $dom = new DOMDocument();
Chris@2 10 $dom->loadXML('<?xml version="1.0" ?><component xmlns="https://phar.io/xml/manifest/1.0" />');
Chris@2 11 $collection = new ComponentElementCollection($dom->childNodes);
Chris@2 12
Chris@2 13 foreach($collection as $componentElement) {
Chris@2 14 $this->assertInstanceOf(ComponentElement::class, $componentElement);
Chris@2 15 }
Chris@2 16 }
Chris@2 17
Chris@2 18 }