diff --git a/object.js b/object.js index a1adfb0..8458e5a 100755 --- a/object.js +++ b/object.js @@ -151,7 +151,9 @@ function(base, obj, non_strict){ return true } -// Like .match(..) but will test if obj's attributes are included in base +// Like .match(..) but will test if obj is a non-strict subset of base... +// +// NOTE: this will only check direct attributes of both base and obj. var matchPartial = module.matchPartial = function(base, obj, non_strict){ diff --git a/test.js b/test.js index c2ecd9a..b0b502f 100755 --- a/test.js +++ b/test.js @@ -321,7 +321,6 @@ var ArgvParser = function(spec){ var setups = module.setups = { // basic constructor and inheritance... - // XXX constructor methods... basic: function(assert){ var X, Y, A, B, C return { @@ -329,11 +328,16 @@ module.setups = { Y: Y = assert(object.C('Y', { }), `C`), A: A = assert(object.C('A', Y, { }), `inherit (gen1)`), - B: B = assert(object.C('B', A, { }, { }), `inherit (gen2)`), + B: B = assert(object.C('B', A, { }, { }), `inherit (gen2) with constructor mixin`), C: C = assert(object.C('C', B, { }), `inherit (gen3)`), } }, - // XXX constructor methods... + /*/ XXX constructor methods or add this to basic... + methods: function(assert){ + return { + } + }, + //*/ // initialization... init: function(assert){