Skip to content

Commit

Permalink
Add tests for #1780
Browse files Browse the repository at this point in the history
  • Loading branch information
dfreedm committed Jun 8, 2015
1 parent ac90bb6 commit abd6f24
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion test/unit/resolveurl.html
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
assert.match(el.$.rel.href, /\?123$/, 'relative href does not preserve query string');
assert.equal(el.$.action.getAttribute('action'), 'foo.z', 'action attribute relativized for incorrect element type');
assert.match(el.$.formAction.action, rx, 'action attribute relativized for incorrect element type');
assert.equal(el.$.hash.getAttribute('href'), '#foo.z', 'hash-only url should not be resolved');
});

test('resolveUrl api', function() {
Expand All @@ -65,7 +66,7 @@

test('resolveUrl api with assetpath', function() {
var el = document.createElement('p-r-ap');
// Manually calculate expected URL, to avoid dependence on
// Manually calculate expected URL, to avoid dependence on
// URL object for this test for IE! Otherwise, would do this:
// var importPath = document.querySelector('#elements').href;
// var expected = new URL('../../assets/Beaker2.jpg', importPath);
Expand Down
1 change: 1 addition & 0 deletions test/unit/sub/resolveurl-elements.html
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
<a id="rel" href="../foo.z?123">Foo</a>
<a id="action" action="foo.z">Foo</a>
<form id="formAction" action="foo.z"></form>
<a id="hash" href="#foo.z">Foo</a>
</template>
</dom-module>
<script>
Expand Down

0 comments on commit abd6f24

Please sign in to comment.