Skip to content
This repository was archived by the owner on Sep 3, 2022. It is now read-only.

Commit 9f2772c

Browse files
authored
Merge pull request #82 from segmentio/logging
add logging for cookie test
2 parents ad40326 + c4205ad commit 9f2772c

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

test/cookie.test.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ describe('cookie', function() {
88
// Just to make sure that
99
// URIError is never thrown here.
1010
document.cookie = 'bad=%';
11+
12+
// enable debugging for cookie package so we can better
13+
// observe flaky tests on IE/Edge.
14+
window.localStorage.setItem('debug', 'cookie');
1115
});
1216

1317
afterEach(function() {
@@ -34,7 +38,10 @@ describe('cookie', function() {
3438

3539
describe('#set', function() {
3640
it('should set a cookie', function() {
41+
// Logging so we can better observe flaky tests on IE/Edge.
42+
console.log('setting cookie. document.cookie is', document.cookie);
3743
cookie.set('x', { a: 'b' });
44+
console.log('cookie set. document.cookie is', document.cookie);
3845
assert.deepEqual(cookie.get('x'), { a: 'b' });
3946
});
4047
});

0 commit comments

Comments
 (0)