view page source - page history - about editing

Revision History: The Problems with Chai

This is revision 551 of the page The Problems with Chai, as it appeared on Mon, 16 Jun 2014 21:50:35 -0700.
Javascript - Testing

Chai is a pretty reasonable testing framework. But there are some key problems that make it much harder than it should be to test.

Very few methods provide an optional message

Both of these assertions will fail with "is not a function". This means the only message you will get back is expected true to be false and expected undefined to be defined. How helpful.

I've created to hopefully resolve this.

define and it cannot have parameterised tests

define 'my thing', ->
  for i in [0..6]
    it 'tests ' + i, ->

This won't work. I haven't found a way to do parameterised tests yet.
Categories: Testing | Chai

view page source - what links to here? - page history - top
Last edited by jevon jevon 57 months ago