I need you to know how i can use AND/OR with should.js I try to do something like that :
res.body[0].color.should.equal('blue').or('red');
It is possible with should ? I find nothing in documentation..Or i'm blind.
Thanks in advance.
I need you to know how i can use AND/OR with should.js I try to do something like that :
res.body[0].color.should.equal('blue').or('red');
It is possible with should ? I find nothing in documentation..Or i'm blind.
Thanks in advance.
There isn't any 'or' operator, but you could do a 'match' regexp:
res.body[0].color.should.match(/^blue$|^red$/);