UNPKG

piglow-clock

Version:
19 lines (13 loc) 395 B
var sandboxed = require('sandboxed-module'); var testUtil = require('../tests/util/util'); var log = []; var piglowInterfaceMock = testUtil.createPiGlowMock(log); var piGlowClock = sandboxed.require('../index', { requires: { "piglow": piglowInterfaceMock } }); piGlowClock.start({}, function() {}); setInterval(function() { console.log(log); }, 1000);