Skip to content

Commit

Permalink
test(client): Fixes thanks to @mgol secret IE knowledge
Browse files Browse the repository at this point in the history
  • Loading branch information
dignifiedquire committed Feb 3, 2016
1 parent 6f19c02 commit 14a06f4
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/client/stringify.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,14 +64,14 @@ describe('stringify', function () {
it('should serialize html', function () {
var div = document.createElement('div')

assert.deepEqual(stringify(div).trim(), '<div></div>')
assert.deepEqual(stringify(div).trim().toLowerCase(), '<div></div>')

div.innerHTML = 'some <span>text</span>'
assert.deepEqual(stringify(div), '<div>some <span>text</span></div>')
assert.deepEqual(stringify(div).trim().toLowerCase(), '<div>some <span>text</span></div>')
})

it('should serialize DOMParser objects', function () {
if (DOMParser) {
if (typeof DOMParser !== 'undefined') {
// Test only works in IE 9 and above
var parser = new DOMParser()
var doc = parser.parseFromString('<test></test>', 'application/xml')
Expand All @@ -81,7 +81,7 @@ describe('stringify', function () {

it('should serialize across iframes', function () {
var div = document.createElement('div')
assert.deepEqual(__karma__.stringify(div).trim(), '<div></div>')
assert.deepEqual(__karma__.stringify(div).trim().toLowerCase(), '<div></div>')

assert.deepEqual(__karma__.stringify([1, 2]), '[1, 2]')
})
Expand Down

0 comments on commit 14a06f4

Please sign in to comment.