Repository navigation
feat(questionnaire-test-toolkit): saved responses, comparison extraction, strict interactions and Health Check acceptance - #27
Closed
pavlushkin wants to merge 4 commits into
Conversation
… extraction and strict interactions - BehavioralTestWrapper accepts questionnaireResponse to load a saved form (resume/amend) and comparisonSourceResponse for modified-only extraction through the existing Save button; caller fixtures are cloned, changing the comparison baseline never rebuilds the form - Initialisation failures render a visible error and no Save button - invokeExtract waits for the callback of the click it dispatched instead of accepting an earlier extraction's result - getBirthDateForAge formats the intended local calendar date directly - Input helpers reject disabled/read-only controls and confirm checkbox, radio and select results instead of silently doing nothing - Public-package regression tests for saved responses, repeats, context resolution, extraction synchronisation, interaction guards, calendar dates and visible init failures; Health Check population assertion updated for the corrected birth date (questionnaire age-expression birthday off-by-one recorded in .scratch/SHC_TOOLKIT_DEFECTS.md)
…ers and Health Check acceptance - BehavioralTestWrapper accepts fetchResourceCallback, mutually exclusive with requestDefinitions and requiring a patient; rejected requests fail the harness visibly even when the population module only warns, and changing the callback rebuilds the form - addRepeatGroup and removeRepeatGroup helpers target stacked repeat instances, never matching nested groups' buttons, and reject disabled controls such as an empty final row or the remaining placeholder - Health Check acceptance scenarios through the callback seam: repaired About fixtures with separate latest-versus-completed QuestionnaireResponse searches, resume in-progress, amend completed against an explicit fresh-population baseline, remove-first medication with association checks, conditional enable/disable/re-enable, age thresholds from explicit DOBs under a fixed Date, and Encounter launch context resolution
The deterministic offline suites (acceptance, population, calculation, conditions and completed-form scenarios) run on push/PR paths affecting the toolkit, renderer, SDC packages or the Health Check suite. The extraction suite performs live SNOMED lookups against Ontoserver and remains opt-in via workflow_dispatch or a [run-live-terminology] commit.
…o the follow-up PR
Member
Author
|
Superseded: this PR is being re-opened against the core repository. Closing. |
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.
Follow-up to aehrc#2193 for the SMART Health Check toolkit update (plan — dependency: this PR is built on top of aehrc#2193's branch and currently targets it so the diff contains only the new work. After aehrc#2193 merges, this PR will be rebased onto
mainand retargeted).What's included
Saved responses and comparison extraction
questionnaireResponseloads a saved response to resume or amend a form; with a patient, saved answers win over newly generated population answers while population still resolves launch context for expressions. Caller fixtures are cloned.comparisonSourceResponseswitches the Save button to modified-only extraction without rebuilding the form or losing unsaved edits.Strict interactions and date correctness
invokeExtractwaits for the callback of the Save click it dispatched rather than accepting an earlier extraction's result.getBirthDateForAgeformats the intended local calendar date directly (no UTC shift). Health Check "Patient details" assertion updated accordingly; the questionnaire age expression's birthday-day off-by-one is recorded as a separate defect.Strict population seam
fetchResourceCallbackprop (mutually exclusive withrequestDefinitions, patient required); rejected requests fail the harness visibly even when the population module only warns.Repeat helpers and Health Check acceptance
addRepeatGroup/removeRepeatGrouphelpers with nested-group button exclusion and disabled-row rejection.CI
workflow_dispatch/[run-live-terminology]).Changelog
Consumer-visible changes are recorded under
Unreleasedin the toolkit changelog. The release version and date will be assigned when preparing publication. These entries extend the sameUnreleasedsection as aehrc#2193.Verification
TZ=Australia/Sydney).@types/fhir@0.0.41alignment).