Permalink
Browse files

add failing object setter test

  • Loading branch information...
1 parent 0b6d3fb commit ed13f49c8999db453812178a4c35dd4767bb92e7 @aheckmann aheckmann committed Mar 30, 2011
Showing with 6 additions and 2 deletions.
  1. +6 −2 test/model.test.js
View
@@ -2772,8 +2772,10 @@ module.exports = {
var t = new T({ nest: null });
- t.nest.should.eql({});
should.strictEqual(t.nest.st, null);
+ t.nest = { st: "jsconf rules" };
+ t.nest.toObject().should.eql({ st: "jsconf rules" });
+ t.nest.st.should.eql("jsconf rules");
db.close();
},
@@ -2792,8 +2794,10 @@ module.exports = {
var t = new T({ nest: undefined });
- t.nest.should.eql({});
should.strictEqual(t.nest.st, undefined);
+ t.nest = { st: "jsconf rules" };
+ t.nest.toObject().should.eql({ st: "jsconf rules" });
+ t.nest.st.should.eql("jsconf rules");
db.close();

0 comments on commit ed13f49

Please sign in to comment.