Permalink
Browse files

add manual test to keyboard invoker

  • Loading branch information...
ferclaverino committed Dec 9, 2016
1 parent c4e9847 commit 913b073f38cc06d4dfeee6f72c984fb39bf206fb
@@ -0,0 +1,23 @@
const KeyboardInvoker = require('../../car/keyboardInvoker');
const commands = {
'q': () => process.exit(),
'up': () => {
console.log('up');
},
'down': () => {
console.log('down');
},
'left': () => {
console.log('left');
},
'right': () => {
console.log('right');
},
'space': () => {
console.log('space');
}
};
const keyboardInvoker = new KeyboardInvoker(commands);
keyboardInvoker.listen();

0 comments on commit 913b073

Please sign in to comment.