Sha256: d2c31902d41d934d4bb09b5d820fd08a12ba3de7af37eeb7e16a8e253840bc04

Contents?: true

Size: 548 Bytes

Versions: 2

Compression:

Stored size: 548 Bytes

Contents

= Assertion Counts

AE tracks the number of assertions made and the number that failed to pass.
We can reset the count using the +recount+ class method.

  Assertion.recount

For example if we one assertion fails and another fails:

  assert(true)
  assert(false)

We will see that AE counted two assertions and one failure.

  Assertion.count.assert == 2
  Assertion.fails.assert == 1

The above calls simply access the actual global variables.

  $assertions.assert == 4
  $failures.assert == 1

Notice there are now two additional assertions.


Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
ae-1.3.0 demo/06_counts.rdoc
ae-1.2.3 qed/06_counts.rdoc