lib/plugins/aws/invokeLocal/index.js/AwsInvokeLocal/invokeLocalRuby
class AwsInvokeLocal:  invokeLocalRuby(runtime, handlerPath, handlerName, event, context) {
    const input = JSON.stringify({
      event: event || {},
      context,
    });

    return new BbPromise(resolve => {
      const ruby = spawn(runtime,
        [path.join(__dirname, 'invoke.rb'), handlerPath, handlerName],
        { env: process.env }, { shell: true });
      ruby.stdout.on('data', (buf) => this.serverless.cli.consoleLog(buf.toString()));
      ruby.stderr.on('data', (buf) => this.serverless.cli.consoleLog(buf.toString()));
      ruby.stdin.write(input);
      ruby.stdin.end();
      ruby.on('close', () => resolve());
    });
  }