// Tests the utils/comb.js helper functions in conjuction with Space.comb (and .copy) const Space = require('../space'); const comb = require('../utils/comb'); let base = new Space(); base.adhoc('\ this is some text\n\ this is the SEARCHSTRING\n\ &&&&&&&&&&&&&&&&&&&&&&&&\n\ empty&chars&&&&&&\n'); base.loc = [0,0]; let mod = base.copy() let bg = new Space(); bg.adhoc('&&trial'); bg.loc = [2,0]; mod.comb(bg, comb.mask); console.log(mod.print()); mod = base.copy() bg.loc = [1,0]; mod.comb(bg, comb.unmask); console.log('-----'); console.log(mod.print());