Add unit-test for "array" type
Add a unit-test to capture the fact that a property type can be specified as `type: 'array'`.
This commit is contained in:
parent
ef0a10dbb6
commit
f4be88357c
|
@ -390,5 +390,15 @@ describe('ModelDefinition class', function () {
|
||||||
done();
|
done();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it('should support "array" type shortcut', function() {
|
||||||
|
var Model = memory.createModel('TwoArrays', {
|
||||||
|
regular: Array,
|
||||||
|
sugar: 'array'
|
||||||
|
});
|
||||||
|
|
||||||
|
var props = Model.definition.properties;
|
||||||
|
props.regular.type.should.equal(props.sugar.type);
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue