Closed twada closed 10 years ago
Provide special purpose value stringify function for power-assert value formatting.
Trying to prune deep Object/Array elements (default depth = 1)
var foo = 'foo', bar = ['toto', 'tata'], baz = {name: 'hoge'}; assert.notDeepEqual([foo,bar,baz], new Array(foo, bar, baz)) | | | | | | | | | | | | | Object{name:"hoge"} | | | | | ["toto","tata"] | | | | "foo" | | | ["foo",#Array#,#Object#] | | Object{name:"hoge"} | ["toto","tata"] "foo"
function Person(name, age) { this.name = name; this.age = age; } var alice = new Person('alice', 3), bob = new Person('bob', 4); assert(alice.age === bob.age) | | | | | | | | | 4 | | | Person{name:"bob",age:4} | 3 false Person{name:"alice",age:3} $$$ [number] bob.age ### [number] alice.age $=> 4 #=> 3
Provide special purpose value stringify function for power-assert value formatting.
Depth-limitation
Trying to prune deep Object/Array elements (default depth = 1)
Value Rendering
Other TODOs