ampersand-state
Advanced tools
Comparing version 4.2.1 to 4.2.2
@@ -9,2 +9,3 @@ var _ = require('underscore'); | ||
options || (options = {}); | ||
if (!this.cid) this.cid = _.uniqueId('state'); | ||
this._values = {}; | ||
@@ -11,0 +12,0 @@ this._definition = Object.create(this._definition); |
{ | ||
"name": "ampersand-state", | ||
"description": "An observable, extensible state object with derived watchable properties.", | ||
"version": "4.2.1", | ||
"version": "4.2.2", | ||
"author": "Henrik Joreteg <henrik@andyet.net>", | ||
@@ -6,0 +6,0 @@ "bugs": { |
@@ -173,2 +173,14 @@ /*jshint expr: true*/ | ||
test('should have cid', function (t) { | ||
var Model = State.extend({ | ||
props: { | ||
id: 'string', | ||
type: 'string' | ||
} | ||
}); | ||
var m = new Model(); | ||
t.ok(m.cid); | ||
t.end(); | ||
}); | ||
test('instanceof checks should pass for all parents in the chain', function (t) { | ||
@@ -175,0 +187,0 @@ var P1 = Person.extend({}); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
73809
1823