Box octo model – add, remove, update state of elements inside box.
var bulp = {
id: 'bulp_1',
state: 'off'
};
var box = new Box();
box.addElement(bulp);
box.setState(bulp_1, 'on');
assert.equal(box.getElementById(bulp.id).state, 'on');npm install– in application root folder.
make test– executes Mocha.make continous– executes Mocha with flag-wfor watching for changes.