I have tried to run the apex tests and generate the test report on source deployed scratchOrg.

report is showing Failure's count as 4 and Outcome as 'Failed' too, still shows the PassRate as 100%.

This is strange.

=== Test Summary
NAME                 VALUE
───────────────────  ─────────────────────────────────────────────────────────────
Outcome              Failed
Tests Ran            2496
Passing              2492
Failing              4
Skipped              0
Pass Rate            100%
Fail Rate            0%
Test Start Time      Oct 7, 2020 9:37 PM
Test Execution Time  7339467 ms
Test Total Time      5169603 ms
Command Time         4115 ms
Hostname             https://saas-innovation-44632-dev-ed.cs10.my.salesforce.com/
Org Id               00DJ0000003Z18pMAC
Username             pr-81-1602103364562@billing.com
Test Run Coverage    61%
Org Wide Coverage    90%

2492/2496 = 99.84%

It appears that sfdx is simply rounding that number up rather than showing any decimals.

Beyond that, that 61% test run coverage is concerning.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.