Closed elsaperelli closed 4 months ago
St.:grey_question: |
Category | Percentage | Covered / Total |
---|---|---|---|
🟢 | Statements | 85.47% (+0.01% 🔼) |
2377/2781 |
🟡 | Branches | 73.28% (+0.04% 🔼) |
2219/3028 |
🟢 | Functions | 88.15% | 424/481 |
🟢 | Lines | 85.81% (+0.01% 🔼) |
2297/2677 |
451 tests passing in 31 suites.
Report generated by 🧪jest coverage report action from de0bba6f9c28dfe3a9ad3589ed21b88a0e6a4216
Summary
Our most recent PR addresses updates to clause coverage calculation and highlighting that were necessary to reflect the functionality of the
3.7.1
version of the cql to elm translator. Due to the nature of changes to localId assignment in the translator versions, this broke just the highlighting of some aliases (no affect to clause coverage calculation) for measures that use older translator versions. This PR makes sure that highlighting is backwards compatible with the older translator version (there should be no change to highlighting).New behavior
I have a comment in the code that details these translator version quirks, but essentially we can't always use the
statement.localId
if it exists for measures that were translated using the other translator. I was able to narrow this down to justWith
statements.Code changes
ClauseResultsHelpers.ts
- ONLY usestatement.localId
if it is NOT a with statement. In the older translator version, with statements require the use of thestatement.expression.localId + 1
. In the new translator version, you will see that these aliases are not highlighted. This is because there is no longer a clear mapping to the localId in the ELM annotation that we want (pending translator fix).Testing guidance
master
branch, you will see that the MAT6725 Good (pre translator change) bundle and test cases produce 99.7% clause coverage highlighting HOWEVER there are aliases that are unhiglighted. On the1.3.3
version offqm-execution
, MAT6725 Good (pre translator change) bundle and test cases produce 99.7% clause coverage highlighting with no highlighting issues. This is the desired behavior. On this branch (alias-highlighting-fix
), the MAT6725 Good (pre translator change) bundle and test cases should produce the SAME results. as1.3.3
(99.7% coverage, no highlighting issues).master
branch, you will see that the MAT6725 Bad (post translator change) bundle and test cases produce 99.5% clause coverage highlighting and there are aliases that are un highlighted. This is to be expected (need translator fix for this). On this branch, we want the same results.1.3.3
.