@ -266,124 +266,124 @@ class ViewTest extends TestCase
public static function pagesDataProvider(): array
public static function pagesDataProvider(): array
{
{
return [
return [
// [
[
// 'page-with-component-with-old-syntax',
'page-with-component-with-old-syntax',
// < < < 'html'
< < < 'html'
// my-component
my-component
// html,
html,
// ],
],
// [
[
// 'page-with-component-with-new-syntax',
'page-with-component-with-new-syntax',
// < < < 'html'
< < < 'html'
// my-component
my-component
// html,
html,
// ],
],
// [
[
// 'page-with-component-with-subcomponent',
'page-with-component-with-subcomponent',
// < < < 'html'
< < < 'html'
// < div >
< div >
// my-component-with-subcomponent
my-component-with-subcomponent
// subcomponent
subcomponent
// < / div >
< / div >
// html,
html,
// ],
],
// [
[
// 'page-with-multiple-components',
'page-with-multiple-components',
// < < < 'html'
< < < 'html'
// < ul >
< ul >
// < li > my-component< / li >
< li > my-component< / li >
// < li > my-component< / li >
< li > my-component< / li >
// < / ul >
< / ul >
// html,
html,
// ],
],
// [
[
// 'page-with-functional-component',
'page-with-functional-component',
// < < < 'html'
< < < 'html'
// my-functional-component
my-functional-component
// html,
html,
// ],
],
// [
[
// 'page-with-class-component',
'page-with-class-component',
// < < < 'html'
< < < 'html'
// my-class-component
my-class-component
// html,
html,
// ],
],
// [
[
// 'page-with-class-component-with-styles',
'page-with-class-component-with-styles',
// < < < 'html'
< < < 'html'
// < span class = "my-class-component-with-styles" >
< span class = "my-class-component-with-styles" >
// my-class-component-with-styles
my-class-component-with-styles
// < / span >
< / span >
// < style >
< style >
// .my-class-component-with-styles {
.my-class-component-with-styles {
// color: red;
color: red;
// }
}
// < / style >
< / style >
// html,
html,
// ],
],
// [
[
// 'page-with-class-component-with-scripts',
'page-with-class-component-with-scripts',
// < < < 'html'
< < < 'html'
// my-class-component-with-scripts
my-class-component-with-scripts
// < script > console . log ( 'my-class-component-with-scripts' ) < / script >
< script > console . log ( 'my-class-component-with-scripts' ) < / script >
// html,
html,
// ],
],
// [
[
// 'page-with-class-component-that-extends-another-class-component',
'page-with-class-component-that-extends-another-class-component',
// < < < 'html'
< < < 'html'
// another-class-component extended by my-class-component-that-extends-another-class-component
another-class-component extended by my-class-component-that-extends-another-class-component
// html,
html,
// ],
],
// [
[
// 'page-with-component-with-one-prop',
'page-with-component-with-one-prop',
// < < < 'html'
< < < 'html'
// < html >
< html >
// < body >
< body >
// < h1 > Hello, James< / h1 >
< h1 > Hello, James< / h1 >
// < / body >
< / body >
// < / html >
< / html >
// html,
html,
// ['name' => 'James'],
['name' => 'James'],
// ],
],
// [
[
// 'page-with-component-with-one-prop',
'page-with-component-with-one-prop',
// < < < 'html'
< < < 'html'
// < html >
< html >
// < body >
< body >
// < h1 > Hello, Victoria< / h1 >
< h1 > Hello, Victoria< / h1 >
// < / body >
< / body >
// < / html >
< / html >
// html,
html,
// ['name' => 'Victoria'],
['name' => 'Victoria'],
// ],
],
// [
[
// 'page-with-component-with-two-props',
'page-with-component-with-two-props',
// < < < 'html'
< < < 'html'
// < html >
< html >
// < body >
< body >
// < h1 > Hello, Astronaut Victoria< / h1 >
< h1 > Hello, Astronaut Victoria< / h1 >
// < / body >
< / body >
// < / html >
< / html >
// html,
html,
// ['name' => 'Victoria', 'occupation' => 'Astronaut'],
['name' => 'Victoria', 'occupation' => 'Astronaut'],
// ],
],
// [
[
// 'page-with-three-different-components',
'page-with-three-different-components',
// < < < 'html'
< < < 'html'
// my-component
my-component
// my-functional-component
my-functional-component
// my-class-component
my-class-component
// html,
html,
// ],
],
// [
[
// 'page-with-component-with-prop-which-value-contains-spaces-and-numbers',
'page-with-component-with-prop-which-value-contains-spaces-and-numbers',
// < < < 'html'
< < < 'html'
// < h1 > Hello, Constantine 1st the Great< / h1 >
< h1 > Hello, Constantine 1st the Great< / h1 >
// html,
html,
// ['name' => 'Constantine 1st the Great'],
['name' => 'Constantine 1st the Great'],
// ],
],
[
[
'page-two-same-components-with-one-style-and-script-tag',
'page-two-same-components-with-one-style-and-script-tag',
< < < 'html'
< < < 'html'