'memory' is already defined

This commit is contained in:
Rob Halff 2014-11-21 02:47:47 +01:00
parent 918497c365
commit 4ee7b5f440
1 changed files with 6 additions and 6 deletions

View File

@ -6,25 +6,25 @@ describe('Memory Connector', function(){
// or create it using the standard
// data source creation api
var memory = loopback.createDataSource({
memory = loopback.createDataSource({
connector: loopback.Memory
});
// create a model using the
// memory data source
var properties = {
name: String,
price: Number
};
var Product = memory.createModel('product', properties);
Product.create([
{name: 'apple', price: 0.79},
{name: 'pear', price: 1.29},
{name: 'orange', price: 0.59},
], count);
function count() {
Product.count(function (err, count) {
assert.equal(count, 3);
@ -32,4 +32,4 @@ describe('Memory Connector', function(){
});
}
});
});
});