Skip to content

Commit

Permalink
Add expect for travis-ci
Browse files Browse the repository at this point in the history
  • Loading branch information
59naga committed Dec 29, 2015
1 parent 0df0867 commit 7995026
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/nicolive/comment.coffee
Expand Up @@ -43,5 +43,6 @@ module.exports= (text,args...,callback)->
@viewer.removeListener 'data',chatResult

{code,description}= status[statusValue]
error= null
error= new Error 'Status is '+statusValue+':'+code+' '+description if statusValue isnt '0'
callback error,data.find('chat_result')
1 change: 1 addition & 0 deletions test/nicolive.spec.coffee
Expand Up @@ -50,6 +50,7 @@ describe 'nicolive',->
viewer.on 'handshaked',->
lastRes= parseInt nicolive.playerStatus.last_res
nicolive.comment text,(error,chat)->
expect(error).toBe null
expect(chat.attr 'thread').toBe nicolive.playerStatus.thread
expect(chat.attr 'status').toBe '0'
expect(chat.attr 'no').toBe (lastRes+1).toString()
Expand Down

0 comments on commit 7995026

Please sign in to comment.