Repository navigation
Use capability codes from the CQL Language Capabilities CodeSystem - #174
Open
bryantaustin13 wants to merge 1 commit into
Open
bryantaustin13 wants to merge 1 commit into
bryantaustin13 wants to merge 1 commit into
Conversation
20 of the capability codes used by the tests were not in http://cql.hl7.org/CodeSystem/cql-language-capabilities, which testSchema.xsd says they must come from. - Replace 15 with their existing equivalents: the date-and-time-operators.* child codes, the query clause codes (single-source, where, let, return, relationships, aggregate) and the system.* type codes, chosen per group. - Drop timing-phrases.within and interval-comparisons, which only appeared in the CqlDateTimeOperatorsTest suite header. - Keep literals, timezone-offset and uncertainty-intervals, and use a new sort-clause-query for the Sort group; these four are added to the CodeSystem in HL7/cql. - In the Today group, list only the operators each test uses; the group itself keeps just date-and-time-operators.today. Only <capability> elements change. Results on HAPI 8.12.0 (CQL 5.5.0) and cql-execution are unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
tests/testSchema.xsdsays a capability code must come from the CQL Language Capability Codes (http://cql.hl7.org/CodeSystem/cql-language-capabilities). 20 of the 41 codes the tests use aren't in that CodeSystem. They were added in b3b1318 before the CodeSystem'sdate-and-time-operators.*child codes existed. This PR moves the tests onto the CodeSystem's codes.Replaced with an existing code (15):
component-extractiondate-and-time-operators.fromconstructor.date/.datetime/.timedate-and-time-operators.date/.datetime/.timedate-time-arithmeticdate-and-time-operators.add(Add, Today) /.subtract(Subtract)difference-indate-and-time-operators.differenceduration-between,precision-based-timingdate-and-time-operators.durationfunction.Now/.Today/.TimeOfDaydate-and-time-operators.now/.today/.timeofdaytiming-phrases.before-afterdate-and-time-operators.before/.after/.same-or-before/.same-or-after, by grouptiming-phrases.same-asdate-and-time-operators.same-asqueriessingle-source-query,where-clause-query,let-clause-query,return-clause-query,relationships-query(With/Without),aggregate-clause-query, by grouptypessystem.date,system.datetime,system.time,system.quantity,system.string,system.long, by group; the Any group and the suite usesystem-data-typesRemoved (2):
timing-phrases.withinandinterval-comparisons. Each appeared only in the CqlDateTimeOperatorsTest suite header, and no test useswithin.Kept, added to the CodeSystem by HL7/cql#106 (4):
literals,timezone-offset,uncertainty-intervals, and the newsort-clause-queryfor the Sort group.The Today group's tests now list only the operators their expressions use, and the group itself keeps only
date-and-time-operators.today. The runner combines a test's codes with its group's codes, so a group-level code would otherwise be reported for every test. For example,Today() = Today()now reports onlydate-and-time-operators.today.Only
<capability>lines change, in CqlDateTimeOperatorsTest.xml, CqlQueryTests.xml and CqlTypesTest.xml. No test changes result: before and after are both 1841/167/29 (pass/fail/skip) on HAPI 8.12.0 / CQL 5.5.0 and 1862/89/86 on cql-execution. All files validate againsttests/testSchema.xsd. The runner loads the same 2037 tests, and every one of the 55 codes now in use is in the CodeSystem once HL7/cql#106 merges.Follow-up: #88 and #166 add more uses of the old codes (
timezone-offset,component-extraction,function.Now,constructor.datetime,types). Whichever merges second should be updated to match.🤖 Generated with Claude Code