c# - Assert.that vs Assert.True -


what prefer:

assert.that(obj.foo, is.equalto(true)) 

or

assert.true(obj.foo) 

for me, both asserts equivalent, 1 should prefered?

in particular case, there no difference: see output of same level of detail (i.e. tells expected evaluate true has evaluated false). same goes for

assert.istrue(obj.foo); 

and

assert.that(obj.foo, is.true); 

your team should pick 1 style of assertions, , stick throughout tests. if team prefers assert.that style, should use assert.that(obj.foo, is.true).


Comments

Popular posts from this blog

node.js - Bad Request - node js ajax post -

Why does Ruby on Rails generate add a blank line to the end of a file? -

keyboard - Smiles and long press feature in Android -