17 $invoker = new \Magento\Framework\App\Utility\AggregateInvoker($this);
24 function ($layoutFile) {
26 $node = simplexml_load_file($layoutFile);
28 $designAbstraction = $node[
'design_abstraction'];
30 if ($designAbstraction) {
31 $issues[] =
'Attribute "design_abstraction" is defined, but "label" is not';
36 $this->fail(
"Issues found in handle declaration:\n" . implode(
"\n", $issues) .
"\n");
43 public function testContainerDeclarations()
45 $invoker = new \Magento\Framework\App\Utility\AggregateInvoker($this);
52 function ($layoutFile) {
54 $xml = simplexml_load_file($layoutFile);
55 $containers = $xml->xpath(
'/layout//container') ?: [];
58 if (!isset($node[
'htmlTag']) && (isset($node[
'htmlId']) || isset($node[
'htmlClass']))) {
59 $issues[] = $node->asXML();
64 'The following containers declare attribute "htmlId" and/or "htmlClass", but not "htmlTag":' .
79 $invoker = new \Magento\Framework\App\Utility\AggregateInvoker($this);
86 function ($layoutFile) {
87 $dom = new \DOMDocument();
88 $dom->load($layoutFile);
89 $xpath = new \DOMXpath($dom);
90 if ($xpath->query(
"//*[@name='head']")->length) {
91 $this->fail(
'Following file contains deprecated head block. File Path:' .
"\n" . $layoutFile);