Permalink
Browse files

Manually require init

  • Loading branch information...
1 parent 2fd2157 commit 43f395d6535876da5507fd2744f5fddeeb719d44 @1602 committed Apr 6, 2013
View
2 Makefile
@@ -1,7 +1,7 @@
## TESTS
TESTER = ./node_modules/.bin/mocha
-OPTS = --require ./test/init.js --growl
+OPTS = --growl
TESTS = test/*.test.js
test:
View
10 test/adapters_test.js
@@ -1,10 +0,0 @@
-var jdb = require('../'),
- Schema = jdb.Schema,
- test = jdb.test;
-
-var schema = new Schema('memory');
-
-test(module.exports, schema);
-
-test.skip('hasMany should be cached');
-
View
4 test/basic-querying.test.js
@@ -1,4 +1,6 @@
-var db, User, should = require('should');
+// This test written in mocha+should.js
+var should = require('./init.js');
+var db, User;
describe('basic-querying', function() {
View
6 test/datatype.test.js
@@ -1,7 +1,9 @@
+// This test written in mocha+should.js
+var should = require('./init.js');
+
var db, Model;
-var should = require('should');
-describe.only('datatypes', function() {
+describe('datatypes', function() {
before(function(done){
db = getSchema();
View
3 test/defaults.test.js
@@ -1,3 +1,6 @@
+// This test written in mocha+should.js
+var should = require('./init.js');
+
var db = getSchema();
describe('defaults', function() {
View
4 test/hooks.test.js
@@ -1,5 +1,7 @@
+// This test written in mocha+should.js
+var should = require('./init.js');
+
var j = require('../'),
- should = require('should'),
Schema = j.Schema,
AbstractClass = j.AbstractClass,
Hookable = j.Hookable,
View
5 test/include.test.js
@@ -1,4 +1,7 @@
-var db, User, Post, Passport, City, Street, Building, should = require('should');
+// This test written in mocha+should.js
+var should = require('./init.js');
+
+var db, User, Post, Passport, City, Street, Building;
var nbSchemaRequests = 0;
describe('include', function() {
View
2 test/init.js
@@ -1,4 +1,4 @@
-require('should');
+module.exports = require('should');
if (!process.env.TRAVIS) {
if (typeof __cov === 'undefined') {
View
4 test/json.test.js
@@ -1,5 +1,7 @@
+// This test written in mocha+should.js
+var should = require('./init.js');
+
var Schema = require('../').Schema;
-var should = require('should');
describe('JSON property', function() {
var schema, Model;
View
3 test/jugglingdb.test.js
@@ -1,3 +1,6 @@
+// This test written in mocha+should.js
+var should = require('./init.js');
+
var jugglingdb = require('../');
describe('jugglingdb', function() {
View
5 test/manipulation.test.js
@@ -1,4 +1,7 @@
-var db, Person, should = require('should');
+// This test written in mocha+should.js
+var should = require('./init.js');
+
+var db, Person;
describe('manipulation', function() {
View
5 test/relations.test.js
@@ -1,4 +1,7 @@
-var db, Book, Chapter, Author, Reader, should = require('should');
+// This test written in mocha+should.js
+var should = require('./init.js');
+
+var db, Book, Chapter, Author, Reader;
describe('relations', function() {
before(function(done) {
View
4 test/schema.test.js
@@ -1,5 +1,7 @@
+// This test written in mocha+should.js
+var should = require('./init.js');
+
var db = getSchema(), slave = getSchema(), Model, SlaveModel;
-var should = require('should');
describe('schema', function() {
View
4 test/validations.test.js
@@ -1,6 +1,8 @@
+// This test written in mocha+should.js
+var should = require('./init.js');
+
var j = require('../'), db, User;
var ValidationError = require('../lib/validations.js').ValidationError;
-var should = require('should');
function getValidAttributes() {
return {

0 comments on commit 43f395d

Please sign in to comment.