可以做一个x.toEqual('hello').or.toEqual('bye')
我希望能够做的Expects,有多个正确的可能性。
发布于 2014-06-26 23:51:32
您总是可以执行返回布尔值的if语句,然后检查该布尔值是否为真。
var test = false;
if(x=='hello' || x=='bye'){
test = true;
}
expect(test).toEqual(true);https://stackoverflow.com/questions/24434826
复制相似问题