PortableInfobox/tests/phpunit/nodes/NodeUnimplementedTest.php

23 lines
519 B
PHP
Raw Normal View History

2018-08-13 14:31:50 +00:00
<?php
use PortableInfobox\Parser\Nodes\NodeUnimplemented;
2022-03-11 20:35:51 +00:00
use PortableInfobox\Parser\Nodes\UnimplementedNodeException;
use PortableInfobox\Parser\XmlParser;
2018-08-16 09:25:53 +00:00
2018-08-13 14:31:50 +00:00
/**
* @group PortableInfobox
2022-03-11 20:35:51 +00:00
* @covers \PortableInfobox\Parser\Nodes\NodeUnimplemented
2018-08-13 14:31:50 +00:00
*/
2021-12-15 22:01:13 +00:00
class NodeUnimplementedTest extends MediaWikiIntegrationTestCase {
2018-08-13 14:31:50 +00:00
public function testNewFromXML() {
2022-03-11 20:35:51 +00:00
$this->expectException( UnimplementedNodeException::class );
2021-09-11 23:07:07 +00:00
2018-08-13 14:31:50 +00:00
( new NodeUnimplemented(
2022-03-11 20:35:51 +00:00
XmlParser::parseXmlString( "<foo/>" ),
2018-08-13 14:31:50 +00:00
[]
) )->getData();
}
2018-08-16 09:25:53 +00:00
}