Page MenuHomePhabricator

Fail Arcanist tests when they make zero assertions
ClosedPublic

Authored by epriestley on Mar 7 2014, 2:23 PM.
Tags
None
Referenced Files
F15537875: D8437.id20032.diff
Thu, Apr 24, 4:16 PM
F15531162: D8437.id20032.diff
Wed, Apr 23, 10:00 AM
F15529321: D8437.id20021.diff
Tue, Apr 22, 6:41 PM
F15515320: D8437.id.diff
Fri, Apr 18, 9:34 AM
F15512510: D8437.diff
Thu, Apr 17, 11:18 AM
F15284224: D8437.diff
Mar 4 2025, 9:26 AM
Unknown Object (File)
Feb 23 2025, 10:16 PM
Unknown Object (File)
Feb 17 2025, 2:02 AM
Subscribers

Details

Summary

Fixes T4570. When a test case doesn't make any assertions, fail it:

  • A tiny fraction of tests pass by not throwing. These tests can easily make a trivial assertion. It took about 5 minutes to fix them all (D8435, D8436).
  • In other cases, no assertions means a test construction problem, as with T4570. In these cases, failing loudly catches a severe error.
  • Fixes the no-assertion test cases in arcanist/
  • Makes the PHP 5.4 test pass for the moment, see discussion in T4334.
Test Plan

Ran arc unit --everything.

Diff Detail

Repository
rARC Arcanist
Branch
notest2
Lint
Lint Passed
Unit
Tests Passed

Event Timeline

btrahan edited edge metadata.
This revision is now accepted and ready to land.Mar 7 2014, 5:51 PM