diff --git a/test/fixtures/a1.js b/test/fixtures/a1.js new file mode 120000 index 00000000000..44001cd1bca --- /dev/null +++ b/test/fixtures/a1.js @@ -0,0 +1 @@ +a.js \ No newline at end of file diff --git a/test/simple/test-module-loading.js b/test/simple/test-module-loading.js index 0011e136190..56515b8850c 100644 --- a/test/simple/test-module-loading.js +++ b/test/simple/test-module-loading.js @@ -58,9 +58,11 @@ try { assert.equal(require('path').dirname(__filename), __dirname); -require.async('../fixtures/a', function (err, a) { +var asyncRun = false; +require.async('../fixtures/a1', function (err, a) { if (err) throw err; assert.equal("A", a.A()); + asyncRun = true; }); debug('load custom file types with registerExtension'); @@ -99,5 +101,7 @@ process.addListener("exit", function () { assert.equal(true, errorThrown); + assert.equal(true, asyncRun); + puts("exit"); });