notes and minor tweaks...

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2020-06-08 04:25:58 +03:00
parent ff9d79a6a5
commit 7e787fe028
2 changed files with 10 additions and 4 deletions

View File

@ -151,7 +151,9 @@ function(base, obj, non_strict){
return true } 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 = var matchPartial =
module.matchPartial = module.matchPartial =
function(base, obj, non_strict){ function(base, obj, non_strict){

10
test.js
View File

@ -321,7 +321,6 @@ var ArgvParser = function(spec){
var setups = var setups =
module.setups = { module.setups = {
// basic constructor and inheritance... // basic constructor and inheritance...
// XXX constructor methods...
basic: function(assert){ basic: function(assert){
var X, Y, A, B, C var X, Y, A, B, C
return { return {
@ -329,11 +328,16 @@ module.setups = {
Y: Y = assert(object.C('Y', { }), `C`), Y: Y = assert(object.C('Y', { }), `C`),
A: A = assert(object.C('A', Y, { }), `inherit (gen1)`), 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)`), 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... // initialization...
init: function(assert){ init: function(assert){