1 | var test = require('tap').test
|
2 | , cls = require('../context.js')
|
3 | ;
|
4 |
|
5 | test("minimized test case that caused #6011 patch to fail", function (t) {
|
6 | t.plan(3);
|
7 |
|
8 | console.log('+');
|
9 |
|
10 | process.nextTick(function () { console.log('!'); });
|
11 |
|
12 | var n = cls.createNamespace("test");
|
13 | t.ok(!n.get('state'), "state should not yet be visible");
|
14 |
|
15 | n.run(function () {
|
16 | n.set('state', true);
|
17 | t.ok(n.get('state'), "state should be visible");
|
18 |
|
19 | process.nextTick(function () {
|
20 | t.ok(n.get('state'), "state should be visible");
|
21 | });
|
22 | });
|
23 | });
|