Make browser-request happy and provide a global shim for XHR in issue225 test

This commit is contained in:
David Humphrey (:humph) david.humphrey@senecacollege.ca 2014-06-11 11:34:10 -04:00
parent 5c9ba07706
commit a38a32d5fb
2 changed files with 2 additions and 1 deletions

View File

@ -88,7 +88,7 @@ module.exports = function(grunt) {
mocha: {
// Run all tests (e.g., tests require()'ed in tests/index.js) and also tests/bugs/issue225.js
// separately, since it can't be included in a browserify build.
command: './node_modules/.bin/mocha --reporter list tests/index.js tests/bugs/issue225.js'
command: './node_modules/.bin/mocha --reporter list tests/index.js && ./node_modules/.bin/mocha --reporter list tests/bugs/issue225.js'
}
},

View File

@ -7,6 +7,7 @@
var requirejs = require('requirejs');
var expect = require('chai').expect;
// browser-request assumes access to XHR
GLOBAL.XMLHttpRequest = {};
describe('require.js should be able to use built Filer, issue 225', function() {