hubot-vsphere-commands
Version:
A hubot script that allows users to interact with the vsphere-rest-api developed by quickjp2 on github.
20 lines (14 loc) • 473 B
text/coffeescript
chai = require 'chai'
sinon = require 'sinon'
chai.use require 'sinon-chai'
expect = chai.expect
describe 'vsphere-commands', ->
beforeEach ->
@robot =
respond: sinon.spy()
hear: sinon.spy()
require('../src/vsphere-commands')(@robot)
it 'registers a respond listener', ->
expect(@robot.respond).to.have.been.calledWith(/hello/)
it 'registers a hear listener', ->
expect(@robot.hear).to.have.been.calledWith(/orly/)