var fs = require('fs');
var orm = require('../../services/orm');

describe('ORM Service', function() {
	describe('after load', function() {
		var instance;
		before(function() {
			instance = orm();
		});

		it('returns a promise', function() {
			instance.must.be.instanceOf(Promise);
		});

		it('assigns models', function *() {
			var files = fs.readdirSync('models');
			var orm = yield instance;
			files.forEach(function(file) {
				orm.must.have.enumerableProperty(file.substring(0,1).toUpperCase() + file.substring(1, file.length-3).toLowerCase());
			});
		});
	});
});
@@ -1,13 +1,71 @@
 var 
-fs = 
+bluebird = require('bluebird');%0Avar fs = bluebird.promisifyAll(
 requ
@@ -73,16 +73,17 @@
 re('fs')
+)
 ;%0Avar or
@@ -397,16 +397,22 @@
  files =
+ yield
  fs.read
@@ -414,17 +414,18 @@
 .readdir
-S
+As
 ync('mod

Make test more async