azendal / tellurium

Asynchronous testing framework for EcmaScript
MIT License
12 stars 3 forks source link

Would be cool if assert had labels #10

Closed sgarza closed 3 months ago

sgarza commented 12 years ago

var x = false; spec.assert(x, 'Variable x').toBe(true); => Variable x is false toBe true

or something like that.

azendal commented 3 months ago

suite.describe('Basic Assertions')(function (describe) { describe.specify('should check if value is equal to expected')(function (spec) { const value = 5; spec.assert(value).withLabel('Check if value is 5').toBe(5); }); });