Skip to content

Commit

Permalink
test(client): Fixes for ie7
Browse files Browse the repository at this point in the history
  • Loading branch information
dignifiedquire committed Feb 12, 2016
1 parent 0f64446 commit 72f845f
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
8 changes: 5 additions & 3 deletions test/client/karma.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -339,9 +339,11 @@ describe('Karma', function () {

k.complete()

clock.tick(20)

assert.notEqual(iframe.src, CURRENT_URL)
// clock.tick() does not work in IE 7
setTimeout(function () {
clock.tick(1)
assert.notEqual(iframe.src, CURRENT_URL)
}, 10)
})

it('should not clear context window upon complete when clearContext config is false', function () {
Expand Down
6 changes: 5 additions & 1 deletion test/client/stringify.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,14 @@ describe('stringify', function () {
assert(stringify(obj).indexOf("{a: 'a'}") > -1)

obj = {constructor: null}
assert(stringify(obj).indexOf('{constructor: null}') > -1)

// IE 7 serializes this to Object{}
var s = stringify(obj)
assert(s.indexOf('{constructor: null}') > -1 || s.indexOf('Object{}') > -1)

obj = Object.create(null)
obj.a = 'a'

assert(stringify(obj).indexOf("{a: 'a'}") > -1)
})

Expand Down

0 comments on commit 72f845f

Please sign in to comment.