Skip to content

Commit

Permalink
test(cases): add additional script and style test cases to html
Browse files Browse the repository at this point in the history
Test empty script and style tag and script with json
  • Loading branch information
remarkablemark committed Jun 1, 2020
1 parent 9c21a17 commit 4e0036a
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions test/cases/html.js
Original file line number Diff line number Diff line change
Expand Up @@ -182,12 +182,24 @@ module.exports = [
},

// script tag
{
name: 'empty script',
data: '<script></script>'
},
{
name: 'script',
data: '<script>console.log(1 < 2);</script>'
},
{
name: 'script with json',
data: '<script type="application/json">{"foo":"bar"}</script>'
},

// style tag
{
name: 'empty style',
data: '<style></style>'
},
{
name: 'style',
data: '<style>body > .foo { color: #f00; }</style>'
Expand Down

0 comments on commit 4e0036a

Please sign in to comment.