Skip to content

Commit

Permalink
Update tests to align with new html_entity_decode flags
Browse files Browse the repository at this point in the history
  • Loading branch information
brianlmoon committed Jun 28, 2023
1 parent 0be2bb3 commit 631ea03
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -100,5 +100,5 @@
],
'statusCode' => 200,
'reasonPhrase' => 'OK',
'body' => '{"version":"1.0","provider_name":"WIRED","provider_url":"https:\\/\\/www.wired.com","author_name":"Wired Staff","author_url":"https:\\/\\/www.wired.com\\/author\\/wired-staff\\/","title":"Review: Yi 4K Action Camera","type":"rich","width":600,"height":338,"html":"<blockquote class=\\"wp-embedded-content\\"><a href=\\"https:\\/\\/www.wired.com\\/2016\\/07\\/review-yi-4k-action-camera\\/\\">Review: Yi 4K Action Camera<\\/a><\\/blockquote>\\n<script type=\'text\\/javascript\'>\\n<!--\\/\\/--><![CDATA[\\/\\/><!--\\n\\t\\t!function(a,b){\\"use strict\\";function c(){if(!e){e=!0;var a,c,d,f,g=-1!==navigator.appVersion.indexOf(\\"MSIE 10\\"),h=!!navigator.userAgent.match(\\/Trident.*rv:11\\\\.\\/),i=b.querySelectorAll(\\"iframe.wp-embedded-content\\");for(c=0;c<i.length;c++)if(d=i[c],!d.getAttribute(\\"data-secret\\")){if(f=Math.random().toString(36).substr(2,10),d.src+=\\"#?secret=\\"+f,d.setAttribute(\\"data-secret\\",f),g||h)a=d.cloneNode(!0),a.removeAttribute(\\"security\\"),d.parentNode.replaceChild(a,d)}else;}}var d=!1,e=!1;if(b.querySelector)if(a.addEventListener)d=!0;if(a.wp=a.wp||{},!a.wp.receiveEmbedMessage)if(a.wp.receiveEmbedMessage=function(c){var d=c.data;if(d.secret||d.message||d.value)if(!\\/[^a-zA-Z0-9]\\/.test(d.secret)){var e,f,g,h,i,j=b.querySelectorAll(\'iframe[data-secret=\\"\'+d.secret+\'\\"]\'),k=b.querySelectorAll(\'blockquote[data-secret=\\"\'+d.secret+\'\\"]\');for(e=0;e<k.length;e++)k[e].style.display=\\"none\\";for(e=0;e<j.length;e++)if(f=j[e],c.source===f.contentWindow){if(f.removeAttribute(\\"style\\"),\\"height\\"===d.message){if(g=parseInt(d.value,10),g>1e3)g=1e3;else if(~~g<200)g=200;f.height=g}if(\\"link\\"===d.message)if(h=b.createElement(\\"a\\"),i=b.createElement(\\"a\\"),h.href=f.getAttribute(\\"src\\"),i.href=d.value,i.host===h.host)if(b.activeElement===f)a.top.location.href=d.value}else;}},d)a.addEventListener(\\"message\\",a.wp.receiveEmbedMessage,!1),b.addEventListener(\\"DOMContentLoaded\\",c,!1),a.addEventListener(\\"load\\",c,!1)}(window,document);\\n\\/\\/--><!]]>\\n<\\/script><iframe sandbox=\\"allow-scripts\\" security=\\"restricted\\" src=\\"https:\\/\\/www.wired.com\\/2016\\/07\\/review-yi-4k-action-camera\\/embed\\/\\" width=\\"600\\" height=\\"338\\" title=\\"&#8220;Review: Yi 4K Action Camera&#8221; &#8212; WIRED\\" frameborder=\\"0\\" marginwidth=\\"0\\" marginheight=\\"0\\" scrolling=\\"no\\" class=\\"wp-embedded-content\\"><\\/iframe>","thumbnail_url":"https:\\/\\/www.wired.com\\/wp-content\\/uploads\\/2016\\/07\\/Yi-4KHP.jpg","thumbnail_width":600,"thumbnail_height":337}'
'body' => '{"version":"1.0","provider_name":"WIRED","provider_url":"https:\\/\\/www.wired.com","author_name":"Wired Staff","author_url":"https:\\/\\/www.wired.com\\/author\\/wired-staff\\/","title":"Review: Yi 4K Action Camera","type":"rich","width":600,"height":338,"html":"<blockquote class=\\"wp-embedded-content\\"><a href=\\"https:\\/\\/www.wired.com\\/2016\\/07\\/review-yi-4k-action-camera\\/\\">Review: Yi 4K Action Camera<\\/a><\\/blockquote>\\n<script type=\'text\\/javascript\'>\\n<!--\\/\\/--><![CDATA[\\/\\/><!--\\n !function(a,b){\\"use strict\\";function c(){if(!e){e=!0;var a,c,d,f,g=-1!==navigator.appVersion.indexOf(\\"MSIE 10\\"),h=!!navigator.userAgent.match(\\/Trident.*rv:11\\\\.\\/),i=b.querySelectorAll(\\"iframe.wp-embedded-content\\");for(c=0;c<i.length;c++)if(d=i[c],!d.getAttribute(\\"data-secret\\")){if(f=Math.random().toString(36).substr(2,10),d.src+=\\"#?secret=\\"+f,d.setAttribute(\\"data-secret\\",f),g||h)a=d.cloneNode(!0),a.removeAttribute(\\"security\\"),d.parentNode.replaceChild(a,d)}else;}}var d=!1,e=!1;if(b.querySelector)if(a.addEventListener)d=!0;if(a.wp=a.wp||{},!a.wp.receiveEmbedMessage)if(a.wp.receiveEmbedMessage=function(c){var d=c.data;if(d.secret||d.message||d.value)if(!\\/[^a-zA-Z0-9]\\/.test(d.secret)){var e,f,g,h,i,j=b.querySelectorAll(\'iframe[data-secret=\\"\'+d.secret+\'\\"]\'),k=b.querySelectorAll(\'blockquote[data-secret=\\"\'+d.secret+\'\\"]\');for(e=0;e<k.length;e++)k[e].style.display=\\"none\\";for(e=0;e<j.length;e++)if(f=j[e],c.source===f.contentWindow){if(f.removeAttribute(\\"style\\"),\\"height\\"===d.message){if(g=parseInt(d.value,10),g>1e3)g=1e3;else if (~~g<200)g=200;f.height=g}if(\\"link\\"===d.message)if(h=b.createElement(\\"a\\"),i=b.createElement(\\"a\\"),h.href=f.getAttribute(\\"src\\"),i.href=d.value,i.host===h.host)if(b.activeElement===f)a.top.location.href=d.value}else;}},d)a.addEventListener(\\"message\\",a.wp.receiveEmbedMessage,!1),b.addEventListener(\\"DOMContentLoaded\\",c,!1),a.addEventListener(\\"load\\",c,!1)}(window,document);\\n\\/\\/--><!]]>\\n<\\/script><iframe sandbox=\\"allow-scripts\\" security=\\"restricted\\" src=\\"https:\\/\\/www.wired.com\\/2016\\/07\\/review-yi-4k-action-camera\\/embed\\/\\" width=\\"600\\" height=\\"338\\" title=\\"&#8220;Review: Yi 4K Action Camera&#8221; &#8212; WIRED\\" frameborder=\\"0\\" marginwidth=\\"0\\" marginheight=\\"0\\" scrolling=\\"no\\" class=\\"wp-embedded-content\\"><\\/iframe>","thumbnail_url":"https:\\/\\/www.wired.com\\/wp-content\\/uploads\\/2016\\/07\\/Yi-4KHP.jpg","thumbnail_width":600,"thumbnail_height":337}'
];
2 changes: 1 addition & 1 deletion tests/fixtures/www.flickr.com.photos-desescribir.php
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@
'height' => 64
]
],
'description' => 'Explore desescribir&#x27;s 618 photos on Flickr!'
'description' => 'Explore desescribir\'s 618 photos on Flickr!'
]
]
];
24 changes: 12 additions & 12 deletions tests/fixtures/www.wired.com..1202600986b37d2c6a30336f82c671f8.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
'authorUrl' => 'https://www.wired.com/author/wired-staff/',
'cms' => null,
'code' => [
'html' => '<blockquote class="wp-embedded-content"><a href="https://www.wired.com/2016/07/review-yi-4k-action-camera/">Review: Yi 4K Action Camera</a></blockquote> <script type=\'text/javascript\'> <!--//--><![CDATA[//><!-- !function(a,b){"use strict";function c(){if(!e){e=!0;var a,c,d,f,g=-1!==navigator.appVersion.indexOf("MSIE 10"),h=!!navigator.userAgent.match(/Trident.*rv:11\\./),i=b.querySelectorAll("iframe.wp-embedded-content");for(c=0;c<i.length;c++)if(d=i[c],!d.getAttribute("data-secret")){if(f=Math.random().toString(36).substr(2,10),d.src+="#?secret="+f,d.setAttribute("data-secret",f),g||h)a=d.cloneNode(!0),a.removeAttribute("security"),d.parentNode.replaceChild(a,d)}else;}}var d=!1,e=!1;if(b.querySelector)if(a.addEventListener)d=!0;if(a.wp=a.wp||{},!a.wp.receiveEmbedMessage)if(a.wp.receiveEmbedMessage=function(c){var d=c.data;if(d.secret||d.message||d.value)if(!/[^a-zA-Z0-9]/.test(d.secret)){var e,f,g,h,i,j=b.querySelectorAll(\'iframe[data-secret="\'+d.secret+\'"]\'),k=b.querySelectorAll(\'blockquote[data-secret="\'+d.secret+\'"]\');for(e=0;e<k.length;e++)k[e].style.display="none";for(e=0;e<j.length;e++)if(f=j[e],c.source===f.contentWindow){if(f.removeAttribute("style"),"height"===d.message){if(g=parseInt(d.value,10),g>1e3)g=1e3;else if(~~g<200)g=200;f.height=g}if("link"===d.message)if(h=b.createElement("a"),i=b.createElement("a"),h.href=f.getAttribute("src"),i.href=d.value,i.host===h.host)if(b.activeElement===f)a.top.location.href=d.value}else;}},d)a.addEventListener("message",a.wp.receiveEmbedMessage,!1),b.addEventListener("DOMContentLoaded",c,!1),a.addEventListener("load",c,!1)}(window,document); //--><!]]> </script><iframe sandbox="allow-scripts" security="restricted" src="https://www.wired.com/2016/07/review-yi-4k-action-camera/embed/" width="600" height="338" title="&#8220;Review: Yi 4K Action Camera&#8221; &#8212; WIRED" frameborder="0" marginwidth="0" marginheight="0" scrolling="no" class="wp-embedded-content"></iframe>',
'html' => '<blockquote class="wp-embedded-content"><a href="https://www.wired.com/2016/07/review-yi-4k-action-camera/">Review: Yi 4K Action Camera</a></blockquote> <script type=\'text/javascript\'> <!--//--><![CDATA[//><!-- !function(a,b){"use strict";function c(){if(!e){e=!0;var a,c,d,f,g=-1!==navigator.appVersion.indexOf("MSIE 10"),h=!!navigator.userAgent.match(/Trident.*rv:11\\./),i=b.querySelectorAll("iframe.wp-embedded-content");for(c=0;c<i.length;c++)if(d=i[c],!d.getAttribute("data-secret")){if(f=Math.random().toString(36).substr(2,10),d.src+="#?secret="+f,d.setAttribute("data-secret",f),g||h)a=d.cloneNode(!0),a.removeAttribute("security"),d.parentNode.replaceChild(a,d)}else;}}var d=!1,e=!1;if(b.querySelector)if(a.addEventListener)d=!0;if(a.wp=a.wp||{},!a.wp.receiveEmbedMessage)if(a.wp.receiveEmbedMessage=function(c){var d=c.data;if(d.secret||d.message||d.value)if(!/[^a-zA-Z0-9]/.test(d.secret)){var e,f,g,h,i,j=b.querySelectorAll(\'iframe[data-secret="\'+d.secret+\'"]\'),k=b.querySelectorAll(\'blockquote[data-secret="\'+d.secret+\'"]\');for(e=0;e<k.length;e++)k[e].style.display="none";for(e=0;e<j.length;e++)if(f=j[e],c.source===f.contentWindow){if(f.removeAttribute("style"),"height"===d.message){if(g=parseInt(d.value,10),g>1e3)g=1e3;else if (~~g<200)g=200;f.height=g}if("link"===d.message)if(h=b.createElement("a"),i=b.createElement("a"),h.href=f.getAttribute("src"),i.href=d.value,i.host===h.host)if(b.activeElement===f)a.top.location.href=d.value}else;}},d)a.addEventListener("message",a.wp.receiveEmbedMessage,!1),b.addEventListener("DOMContentLoaded",c,!1),a.addEventListener("load",c,!1)}(window,document); //--><!]]> </script><iframe sandbox="allow-scripts" security="restricted" src="https://www.wired.com/2016/07/review-yi-4k-action-camera/embed/" width="600" height="338" title="&#8220;Review: Yi 4K Action Camera&#8221; &#8212; WIRED" frameborder="0" marginwidth="0" marginheight="0" scrolling="no" class="wp-embedded-content"></iframe>',
'width' => 600,
'height' => 338,
'ratio' => 56.333
Expand Down Expand Up @@ -80,7 +80,7 @@
'html' => '<blockquote class="wp-embedded-content"><a href="https://www.wired.com/2016/07/review-yi-4k-action-camera/">Review: Yi 4K Action Camera</a></blockquote>
<script type=\'text/javascript\'>
<!--//--><![CDATA[//><!--
!function(a,b){"use strict";function c(){if(!e){e=!0;var a,c,d,f,g=-1!==navigator.appVersion.indexOf("MSIE 10"),h=!!navigator.userAgent.match(/Trident.*rv:11\\./),i=b.querySelectorAll("iframe.wp-embedded-content");for(c=0;c<i.length;c++)if(d=i[c],!d.getAttribute("data-secret")){if(f=Math.random().toString(36).substr(2,10),d.src+="#?secret="+f,d.setAttribute("data-secret",f),g||h)a=d.cloneNode(!0),a.removeAttribute("security"),d.parentNode.replaceChild(a,d)}else;}}var d=!1,e=!1;if(b.querySelector)if(a.addEventListener)d=!0;if(a.wp=a.wp||{},!a.wp.receiveEmbedMessage)if(a.wp.receiveEmbedMessage=function(c){var d=c.data;if(d.secret||d.message||d.value)if(!/[^a-zA-Z0-9]/.test(d.secret)){var e,f,g,h,i,j=b.querySelectorAll(\'iframe[data-secret="\'+d.secret+\'"]\'),k=b.querySelectorAll(\'blockquote[data-secret="\'+d.secret+\'"]\');for(e=0;e<k.length;e++)k[e].style.display="none";for(e=0;e<j.length;e++)if(f=j[e],c.source===f.contentWindow){if(f.removeAttribute("style"),"height"===d.message){if(g=parseInt(d.value,10),g>1e3)g=1e3;else if(~~g<200)g=200;f.height=g}if("link"===d.message)if(h=b.createElement("a"),i=b.createElement("a"),h.href=f.getAttribute("src"),i.href=d.value,i.host===h.host)if(b.activeElement===f)a.top.location.href=d.value}else;}},d)a.addEventListener("message",a.wp.receiveEmbedMessage,!1),b.addEventListener("DOMContentLoaded",c,!1),a.addEventListener("load",c,!1)}(window,document);
!function(a,b){"use strict";function c(){if(!e){e=!0;var a,c,d,f,g=-1!==navigator.appVersion.indexOf("MSIE 10"),h=!!navigator.userAgent.match(/Trident.*rv:11\\./),i=b.querySelectorAll("iframe.wp-embedded-content");for(c=0;c<i.length;c++)if(d=i[c],!d.getAttribute("data-secret")){if(f=Math.random().toString(36).substr(2,10),d.src+="#?secret="+f,d.setAttribute("data-secret",f),g||h)a=d.cloneNode(!0),a.removeAttribute("security"),d.parentNode.replaceChild(a,d)}else;}}var d=!1,e=!1;if(b.querySelector)if(a.addEventListener)d=!0;if(a.wp=a.wp||{},!a.wp.receiveEmbedMessage)if(a.wp.receiveEmbedMessage=function(c){var d=c.data;if(d.secret||d.message||d.value)if(!/[^a-zA-Z0-9]/.test(d.secret)){var e,f,g,h,i,j=b.querySelectorAll(\'iframe[data-secret="\'+d.secret+\'"]\'),k=b.querySelectorAll(\'blockquote[data-secret="\'+d.secret+\'"]\');for(e=0;e<k.length;e++)k[e].style.display="none";for(e=0;e<j.length;e++)if(f=j[e],c.source===f.contentWindow){if(f.removeAttribute("style"),"height"===d.message){if(g=parseInt(d.value,10),g>1e3)g=1e3;else if (~~g<200)g=200;f.height=g}if("link"===d.message)if(h=b.createElement("a"),i=b.createElement("a"),h.href=f.getAttribute("src"),i.href=d.value,i.host===h.host)if(b.activeElement===f)a.top.location.href=d.value}else;}},d)a.addEventListener("message",a.wp.receiveEmbedMessage,!1),b.addEventListener("DOMContentLoaded",c,!1),a.addEventListener("load",c,!1)}(window,document);
//--><!]]>
</script><iframe sandbox="allow-scripts" security="restricted" src="https://www.wired.com/2016/07/review-yi-4k-action-camera/embed/" width="600" height="338" title="&#8220;Review: Yi 4K Action Camera&#8221; &#8212; WIRED" frameborder="0" marginwidth="0" marginheight="0" scrolling="no" class="wp-embedded-content"></iframe>',
'thumbnail_url' => 'https://www.wired.com/wp-content/uploads/2016/07/Yi-4KHP.jpg',
Expand Down Expand Up @@ -152,7 +152,7 @@
'articleSection' => 'culture',
'author' => [
'@type' => 'Person',
'name' => 'Geek&#039;s Guide to the Galaxy'
'name' => 'Geek\'s Guide to the Galaxy'
],
'description' => 'Ursula K. Le Guin\'s 1974 novel, about a society with no government or laws, remains a thoughtful exploration of politics and economics decades later.',
'image' => [
Expand Down Expand Up @@ -189,7 +189,7 @@
'articleSection' => 'culture',
'author' => [
'@type' => 'Person',
'name' => 'Geek&#039;s Guide to the Galaxy'
'name' => 'Geek\'s Guide to the Galaxy'
],
'description' => 'The story-driven genre is enjoying an indie renaissance, thanks to new tools that are making the coding process simpler than ever.',
'image' => [
Expand Down Expand Up @@ -226,7 +226,7 @@
'articleSection' => 'culture',
'author' => [
'@type' => 'Person',
'name' => 'Geek&#039;s Guide to the Galaxy'
'name' => 'Geek\'s Guide to the Galaxy'
],
'description' => 'But Everybody Has a Podcast (Except You) author Griffin McElroy can help.',
'image' => [
Expand Down Expand Up @@ -263,7 +263,7 @@
'articleSection' => 'culture',
'author' => [
'@type' => 'Person',
'name' => 'Geek&#039;s Guide to the Galaxy'
'name' => 'Geek\'s Guide to the Galaxy'
],
'description' => 'The Amazon series Upload shows a comedic—and probably more realistic—version of what would happen if humans could live online after they die.',
'image' => [
Expand Down Expand Up @@ -300,7 +300,7 @@
'articleSection' => 'culture',
'author' => [
'@type' => 'Person',
'name' => 'Geek&#039;s Guide to the Galaxy'
'name' => 'Geek\'s Guide to the Galaxy'
],
'description' => 'Ultima artist Denis Loubet knows this for a fact.',
'image' => [
Expand Down Expand Up @@ -338,7 +338,7 @@
'articleSection' => 'culture',
'author' => [
'@type' => 'Person',
'name' => 'Geek&#039;s Guide to the Galaxy'
'name' => 'Geek\'s Guide to the Galaxy'
],
'description' => 'The new Netflix animated series puts a new spin on old tales.',
'image' => [
Expand Down Expand Up @@ -375,7 +375,7 @@
'articleSection' => 'culture',
'author' => [
'@type' => 'Person',
'name' => 'Geek&#039;s Guide to the Galaxy'
'name' => 'Geek\'s Guide to the Galaxy'
],
'description' => 'David Gerrold\'s new novel Hella is about a low-gravity planet inhabited by dinosaur-like aliens. It does deep on the logistics of settling an alien planet.',
'image' => [
Expand Down Expand Up @@ -412,7 +412,7 @@
'articleSection' => 'culture',
'author' => [
'@type' => 'Person',
'name' => 'Geek&#039;s Guide to the Galaxy'
'name' => 'Geek\'s Guide to the Galaxy'
],
'description' => 'Ruth Wilson\'s character is the highlight of HBO\'s His Dark Materials.',
'image' => [
Expand Down Expand Up @@ -526,7 +526,7 @@
'articleSection' => 'culture',
'author' => [
'@type' => 'Person',
'name' => 'Geek&#039;s Guide to the Galaxy'
'name' => 'Geek\'s Guide to the Galaxy'
],
'description' => 'The story-driven genre is enjoying an indie renaissance, thanks to new tools that are making the coding process simpler than ever.',
'image' => [
Expand Down Expand Up @@ -640,7 +640,7 @@
'articleSection' => 'culture',
'author' => [
'@type' => 'Person',
'name' => 'Geek&#039;s Guide to the Galaxy'
'name' => 'Geek\'s Guide to the Galaxy'
],
'description' => 'Ursula K. Le Guin\'s 1974 novel, about a society with no government or laws, remains a thoughtful exploration of politics and economics decades later.',
'image' => [
Expand Down

0 comments on commit 631ea03

Please sign in to comment.