ruff-app-runner module provides you a facility for Ruff driver developers to run driver on their development machine. You may include this module with
var assert = require('assert');
Ruff driver runner creates a virtual runtime built with
ruff-mock, which allows developers to:
- Retrive mock interface
The second parameter of
run function of driver runner is
context. Where the interface could be retrived from
var gpio = context.inputs['gpio'];
The name of the reference for
context.inputs should be same with the name described in
Please checkout Ruff Mock for more information.
driverPathrefer to your driver path which contains
runCallbackwill run once the virtual runtime has been created and your
attachfunction has been invoked.