-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Abhilash Nanda
committed
May 28, 2016
1 parent
76bf4de
commit 581ba95
Showing
8 changed files
with
63 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,21 @@ | ||
'use strict'; | ||
require('app-module-path').addPath(__dirname + "/.."); | ||
|
||
var assert = require('assert'); | ||
let assert = require('assert'); | ||
require('co-mocha'); | ||
|
||
var UserRepo = require('src/repos/UserRepo'); | ||
let UserRepo = require('src/repos/UserRepo'); | ||
|
||
describe('UserRepo testing', function() { | ||
it('should instantiate', function * () { | ||
var userRepo = new UserRepo(); | ||
let userRepo = new UserRepo(); | ||
assert.equal(typeof userRepo, 'object'); | ||
}) | ||
|
||
it('should take parameters', function * () { | ||
var userRepo = new UserRepo({name: 'test', email: '[email protected]'}); | ||
assert.equal(userRepo.name, 'test'); | ||
assert.equal(userRepo.email, '[email protected]'); | ||
let userRepo = new UserRepo({name: 'test', email: '[email protected]'}); | ||
let props = yield userRepo.getProperties(); | ||
assert.equal(props.name, 'test'); | ||
assert.equal(props.email, '[email protected]'); | ||
}) | ||
}); |