mediawiki-skins-MinervaNeue/tests
Stephen Niedzielski 9ccad5a405 Hygiene: replace calledOnce / Twice w/ callCount
Replace all test assertions for calledOnce / Twice with callCount.
assert.ok( calledOnce / Twice ) only lets the dev know that a test
fails. assert.strictEqual( callCount, EXPECTATION ) starts the debugging
process when it fails since it provides the difference in the failure
output. strictEqual() was deliberately used since it's a saner default
and the codebase already favors === equivalency checks.

  find tests -name \*.js|
  xargs -rd\\n sed -ri '
    s%ok\(([^,]+)calledOnce%strictEqual(\1callCount, 1%g;
    s%ok\(([^,]+)calledTwice%strictEqual(\1callCount, 2%g;
  '

Change-Id: I5c4c595c4520cecfad46d652f639a63a1c2c00b4
2018-05-08 16:12:04 +00:00
..
browser QA: Speed up browser tests by not unnecessarily opting into beta 2018-04-04 15:07:30 -07:00
phpunit Simplify SkinUserPageHelper constructor 2018-04-15 16:38:50 -07:00
qunit Hygiene: replace calledOnce / Twice w/ callCount 2018-05-08 16:12:04 +00:00