Enable tests on the logging summary report. #12065
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Overview
Add tests to logging summary report
This is a preliminary fix to get testing working before doing any further fixes.
Before
Tests not enabled for logging summary
After
Tests enabled
Technical Details
I have tested this on mysql 5.6 with full group by mode enabled. I think as a benchmark this is more generic than 5.7 (which has features not in common with MariaDB. I disabled full group temporarily before non-compliant queries (which is the status quo but prevents hard-fails).
The tests use the api which does not call postProcess (as it is often problematic) so I had to move code to functions that it DOES call (this has been done for most other reports previously)
I removed this CRM_Utils_SQL::supportsFullGroupBy() from the enable & disable functions as it gives false negatives and the mysql checks are more accurate. We are not using any functionality that is 5.7 specific (like any value) so this is good. It would be good to confirm this test / report runs in a maria DB full group by scenario - who has that set up? @mlutfy ?
Comments
@seamuslee001 @monishdeb Despite seeming like a lot of change this is mostly just extraction of functions. I can break out into a couple of refactor commits for reviewability over the next day or so.
A simple one is already created here #12066