diff --git a/tests/node-runner.js b/tests/node-runner.js index a6af575..cde792e 100644 --- a/tests/node-runner.js +++ b/tests/node-runner.js @@ -1,9 +1,15 @@ // If there's something broken in filer or a test, // requirejs can blow up, and mocha sees it as tests // not getting added (i.e., it just exists with only -// 1 test run). Display an error so it's clear what happened. +// 1 test run). Display an error and crash loudly +// so it's clear what happened. process.on('uncaughtException', function(err) { - console.error('Error in require.js trying to build test suite, filer:\n', err.stack); + describe('requirejs errors: ', function() { + it('requirejs has crashed building the test suite...', function(done) { + console.error(err.stack); + require('assert').ok(false); + }); + }); }); var requirejs = require('requirejs'); diff --git a/tests/spec/providers/providers.memory.spec.js b/tests/spec/providers/providers.memory.spec.js old mode 100644 new mode 100755 index 6718182..76f5fc5 --- a/tests/spec/providers/providers.memory.spec.js +++ b/tests/spec/providers/providers.memory.spec.js @@ -12,39 +12,6 @@ define(["Filer"], function(Filer) { expect(memoryProvider.getReadWriteContext).to.be.a('function'); }); - describe("Memory provider DBs are sharable", function() { - it("should share a single memory db when name is the same", function(done) { - var provider1; - var provider2; - var provider3; - var name1 = 'memory-db'; - var name2 = 'memory-db2'; - - provider1 = new Filer.FileSystem.providers.Memory(name1); - provider1.open(function(error, firstAccess) { - expect(error).not.to.exist; - expect(firstAccess).to.be.true; - - provider2 = new Filer.FileSystem.providers.Memory(name1); - provider2.open(function(error, firstAccess) { - expect(error).not.to.exist; - expect(firstAccess).to.be.false; - expect(provider1.db).to.equal(provider2.db); - - provider3 = new Filer.FileSystem.providers.Memory(name2); - provider3.open(function(error, firstAccess) { - expect(error).not.to.exist; - expect(firstAccess).to.be.true; - expect(provider3.db).not.to.equal(provider2.db); - - done(); - }); - }); - }); - }); - }); - }); - describe("open an Memory provider", function() { it("should open a new Memory database", function(done) { var provider = new Filer.FileSystem.providers.Memory(); diff --git a/tests/test-manifest.js b/tests/test-manifest.js index 9020697..081847a 100644 --- a/tests/test-manifest.js +++ b/tests/test-manifest.js @@ -42,7 +42,6 @@ define([ // Filer.FileSystem.providers.* "spec/providers/providers.spec", - "spec/providers/providers.memory.spec", "spec/providers/providers.indexeddb.spec", "spec/providers/providers.websql.spec", @@ -68,11 +67,9 @@ define([ "spec/node-js/simple/test-fs-watch", "spec/node-js/simple/test-fs-watch-recursive", - // Nodejs compatibility - "spec/node-js/simple/nodejs.spec", - // Regressions, Bugs "bugs/issue105", - "bugs/issue106" + "bugs/issue106" , + "spec/providers/providers.memory.spec" ]);