-
-
Notifications
You must be signed in to change notification settings - Fork 825
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Max out smarty grumpiness in unit tests - obviously failed - need to figure out why (tests should have failed) #22405
Conversation
(Standard links)
|
1f2f359
to
1d422e1
Compare
CRM/Core/Smarty.php
Outdated
* @return bool | ||
*/ | ||
private static function isTestEnvironment(): bool { | ||
return CRM_Core_Config::singleton()->userFramework === 'CRM_Utils_System_UnitTests'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this right? Would it just be 'UnitTests'?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also bootstrap defines CIVICRM_TEST and I've seen that used elsewhere, and so also works when running in a real CMS.
Just looking at the log so far this broke jenkins while still at the letter "A", so most of the 👍 ⭐ |
Looks like it started failing here not ok 224 - Error: CRM_Case_BAO_CaseTest::testCaseActivity |
I see |
Ok I can look at 22470. |
I've found the thing in the activity tests (or at least one thing) |
7f795c9
to
caa2e20
Compare
This looks like the current fail - I think #22470 will get past that notice |
currently falling over on the isset on totalTaxAmount in the contribution template - this value could be cast from the |
ok - this would fix the current fail #22560 |
d4490b7
to
b16b7a4
Compare
b781f93
to
796f243
Compare
96d41de
to
04891b2
Compare
f09c420
to
fd796ca
Compare
The empty check on templateSelected was added to stop tests failing on a smarty notice. However, this still causes a smarty notice (and test fails) in grumpy smarty mode. Hence this re-fixes in by moving the check to only be done for the from (the sms Upload form) that assigns it
Also fix test to only expect balance if it is sane for there to be one...
Overview
Max out smarty grumpiness in unit tests
Before
Happy smarty
After
Frowny smarty
Technical Details
Comments