Manually require init
This commit is contained in:
parent
2fd2157d28
commit
43f395d653
2
Makefile
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:
|
||||
|
|
|
@ -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');
|
||||
|
|
@ -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() {
|
||||
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
var db, Model;
|
||||
var should = require('should');
|
||||
// This test written in mocha+should.js
|
||||
var should = require('./init.js');
|
||||
|
||||
describe.only('datatypes', function() {
|
||||
var db, Model;
|
||||
|
||||
describe('datatypes', function() {
|
||||
|
||||
before(function(done){
|
||||
db = getSchema();
|
||||
|
|
|
@ -1,3 +1,6 @@
|
|||
// This test written in mocha+should.js
|
||||
var should = require('./init.js');
|
||||
|
||||
var db = getSchema();
|
||||
|
||||
describe('defaults', function() {
|
||||
|
|
|
@ -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,
|
||||
|
|
|
@ -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() {
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
require('should');
|
||||
module.exports = require('should');
|
||||
|
||||
if (!process.env.TRAVIS) {
|
||||
if (typeof __cov === 'undefined') {
|
||||
|
|
|
@ -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;
|
||||
|
|
|
@ -1,3 +1,6 @@
|
|||
// This test written in mocha+should.js
|
||||
var should = require('./init.js');
|
||||
|
||||
var jugglingdb = require('../');
|
||||
|
||||
describe('jugglingdb', function() {
|
||||
|
|
|
@ -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() {
|
||||
|
||||
|
|
|
@ -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) {
|
||||
|
|
|
@ -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() {
|
||||
|
||||
|
|
|
@ -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 {
|
||||
|
|
Loading…
Reference in New Issue