Skip to content

Commit

Permalink
fix node baseURL
Browse files Browse the repository at this point in the history
  • Loading branch information
guybedford committed Nov 18, 2014
1 parent 69cc39b commit 6beeaab
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion lib/extension-core.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ function core(loader) {
var baseURI;
if (typeof window == 'undefined' &&
typeof WorkerGlobalScope == 'undefined') {
baseURI = process.cwd() + '/';
baseURI = 'file:' + process.cwd() + '/';
}
// Inside of a Web Worker
else if(typeof window == 'undefined') {
Expand Down
6 changes: 3 additions & 3 deletions test/test.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
"format global";

(function() {
(function(global) {

QUnit.config.testTimeout = 2000;

Expand Down Expand Up @@ -550,7 +550,7 @@ asyncTest('Importing a mapped loaded module', function() {

asyncTest('Loading empty ES6', function() {
System['import']('tests/empty-es6').then(function(m) {
ok(m && window.emptyES6);
ok(m && emptyES6);
start();
}, err);
})
Expand Down Expand Up @@ -638,4 +638,4 @@ if(typeof window !== 'undefined' && window.Worker) {
});
}

})();
})(typeof window == 'undefined' ? global : window);
4 changes: 3 additions & 1 deletion test/tests/empty-es6.js
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
window.emptyES6 = true;
(function(global) {
global.emptyES6 = true;
})(typeof window == 'undefined' ? global : window);

0 comments on commit 6beeaab

Please sign in to comment.