Skip to content

Commit

Permalink
[TASK] Add two test cases for ResourceMatcherTest
Browse files Browse the repository at this point in the history
  • Loading branch information
ervaude committed Jul 9, 2020
1 parent 5aca585 commit 8698886
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions Tests/Unit/ResourceMatcherTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,16 @@ public function matchDataProvider()
['https://www.example.com/myfile.js'],
[]
],
'simple script tag with parameter' => [
'<script src="https://www.example.com/myfile.js?foo" />',
['https://www.example.com/myfile.js?foo'],
[]
],
'simple script tag with parameter and value' => [
'<script src="https://www.example.com/myfile.js?foo=bar" />',
['https://www.example.com/myfile.js?foo=bar'],
[]
],
'multiple script tags' => [
'<script src="https://www.example.com/myfile.js" /><link><script src="/myfile.js"></script>',
['https://www.example.com/myfile.js', '/myfile.js'],
Expand Down

0 comments on commit 8698886

Please sign in to comment.