-
Notifications
You must be signed in to change notification settings - Fork 7
added tests for timezone offset tests #88
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
Open
bryantaustin13
wants to merge
6
commits into
cqframework:main
Choose a base branch
from
bryantaustin13:issue81_Timezoneoffset-policy-tests
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 1 commit
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
bdfdf4e
added tests for timezone offset tests
bryantaustin13 1e1a3e9
commen/explanationt added for TimezoneOffsetExtraction_NoDefaultOffse…
bryantaustin13 f57d83e
change of output to be more correct
bryantaustin13 3b62d79
Merge branch 'main' into issue81_Timezoneoffset-policy-tests
bryantaustin13 3b55fd1
adjusted timezone offset test
bryantaustin13 fe4a7de
comment added to DateTimeDifferenceWeeks3 for why output should be di…
bryantaustin13 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,51 @@ | ||
| <?xml version="1.0" encoding="utf-8"?> | ||
| <tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://hl7.org/fhirpath/tests" xsi:schemaLocation="http://hl7.org/fhirpath/tests ../../testSchema/testSchema.xsd" | ||
| name="CqlTimeZoneOffsetTest" reference="https://cql.hl7.org/09-b-cqlreference.html#datetime-operators-2" version="1.4"> | ||
| <capability code="timezone-offset"/> | ||
| <capability code="component-extraction"/> | ||
| <capability code="timezone-offset-policy.no-default-offset"/> | ||
| <group name="Policy: No default offset (preserve offset-less)" version="1.5"> | ||
| <test name="DateTimeEquality_NoDefaultOffset_NullWhenComparingOffsetlessToOffset" version="1.5"> | ||
| <capability code="timezone-offset"/> | ||
| <capability code="component-extraction"/> | ||
| <capability code="timezone-offset-policy.no-default-offset"/><!-- Offset-less vs explicit UTC --> | ||
| <expression>@2012-04-01T00:00 = @2012-04-01T00:00+00:00</expression> | ||
| <output>true</output> | ||
| </test> | ||
| <test name="TimezoneOffsetExtraction_NoDefaultOffset_ReturnsNull" version="1.5"> | ||
| <capability code="timezone-offset"/> | ||
| <capability code="component-extraction"/> | ||
| <capability code="timezone-offset-policy.no-default-offset"/> | ||
| <expression>timezoneoffset from @2012-04-01T00:00</expression> | ||
| <output>true</output> | ||
| </test> | ||
| <test name="DateTimeOrdering_NoDefaultOffset_NullWhenOffsetlessVsOffset" version="1.5"> | ||
| <capability code="timezone-offset"/> | ||
| <capability code="timezone-offset-policy.no-default-offset"/> | ||
| <expression>@2012-04-01T00:00 < @2012-04-01T00:00+00:00</expression> | ||
| <output>true</output> | ||
| </test> | ||
| </group> | ||
| <group name="Policy: Default to server offset (normalize offset-less to server)"> | ||
|
bryantaustin13 marked this conversation as resolved.
Outdated
|
||
| <test name="TimezoneOffsetExtraction_DefaultServerOffset_MatchesServer" version="1.5"> | ||
| <capability code="timezone-offset"/> | ||
| <capability code="component-extraction"/> | ||
| <capability code="timezone-offset-policy.default-server-offset"/> | ||
| <expression>(timezoneoffset from @2012-04-01T00:00) = (timezoneoffset from Now())</expression> | ||
| <output>true</output> | ||
| </test> | ||
| <test name="DateTimeEquality_DefaultServerOffset_EqualsWhenExplicitServerOffsetGiven" version="1.5"> | ||
| <capability code="timezone-offset"/> | ||
| <capability code="timezone-offset-policy.default-server-offset"/> | ||
| <expression>@2012-04-01T00:00 = @2012-04-01T00:00{{SERVER_OFFSET_ISO}}</expression> | ||
|
bryantaustin13 marked this conversation as resolved.
|
||
| <output>true</output> | ||
| </test> | ||
| <test name="DateTimeOrdering_DefaultServerOffset_Deterministic" version="1.5"> | ||
| <capability code="timezone-offset"/> | ||
| <capability code="timezone-offset-policy.default-server-offset"/> | ||
| <!-- If both normalize to the same instant, < is false --> | ||
| <expression>@2012-04-01T00:00 < @2012-04-01T00:00{{SERVER_OFFSET_ISO}}</expression> | ||
| <output>false</output> | ||
| </test> | ||
| </group> | ||
| </tests> | ||
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.
Uh oh!
There was an error while loading. Please reload this page.