Skip to content

fhir-gen: Add tests against fhir code generator #1619

Merged
josephjclark merged 6 commits intomainfrom
feature/1585-fhir-gen-tests
Apr 7, 2026
Merged

fhir-gen: Add tests against fhir code generator #1619
josephjclark merged 6 commits intomainfrom
feature/1585-fhir-gen-tests

Conversation

@hunterachieng
Copy link
Copy Markdown
Contributor

Summary

Add tests against fhir code generator.

generateCode() Returns { profiles. ...rest}. profiles is a string an cannot be used as a builder function.
To use builders, we have to have a code eval to check agains the outputs.

To keep it simple, we started with checking the validity of the returned string.

Fixes #

Details

Add technical details of what you've changed (and why).

AI Usage

Please disclose how you've used AI in this work (it's cool, we just want to
know!):

  • I have used Claude Code
  • I have used another model
  • I have not used AI

You can read more details in our
Responsible AI Policy

Review Checklist

Before merging, the reviewer should check the following items:

  • Does the PR do what it claims to do?
  • If this is a new adaptor, added the adaptor on marketing website ?
  • If this PR includes breaking changes, do we need to update any jobs in
    production? Is it safe to release?
  • Are there any unit tests?
  • Is there a changeset associated with this PR? Should there be? Note that
    dev only changes don't need a changeset.
  • Have you ticked a box under AI Usage?

Signed-off-by: Hunter Achieng <achienghunter@gmail.com>
Comment thread tools/generate-fhir/test/generate-code.test.ts Outdated
Signed-off-by: Hunter Achieng <achienghunter@gmail.com>
Comment thread tools/generate-fhir/test/generate-code.test.ts Outdated
Comment thread tools/generate-fhir/test/generate-code.test.ts Outdated
Comment thread tools/generate-fhir/test/generate-code.test.ts Outdated
Comment thread tools/generate-fhir/test/generate-code.test.ts Outdated
Comment thread tools/generate-fhir/test/generate-code.test.ts Outdated
Signed-off-by: Hunter Achieng <achienghunter@gmail.com>
Comment thread tools/generate-fhir/test/generate-code.test.ts Outdated
Comment thread tools/generate-fhir/test/generate-code.test.ts Outdated
Comment thread tools/generate-fhir/test/generate-code.test.ts Outdated
Comment thread tools/generate-fhir/test/generate-code.test.ts Outdated
Comment thread tools/generate-fhir/test/generate-code.test.ts Outdated
Comment thread tools/generate-fhir/test/generate-code.test.ts Outdated
Signed-off-by: Hunter Achieng <achienghunter@gmail.com>
Signed-off-by: Hunter Achieng <achienghunter@gmail.com>
@hunterachieng
Copy link
Copy Markdown
Contributor Author

@josephjclark I have fixed the comments

Comment thread tools/generate-fhir/test/generate-code.test.ts Outdated
Comment thread tools/generate-fhir/test/generate-code.test.ts Outdated
Signed-off-by: Hunter Achieng <achienghunter@gmail.com>
Copy link
Copy Markdown
Collaborator

@josephjclark josephjclark left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great. We'll need to add more tests over time but let's merge this for now

@josephjclark josephjclark merged commit 067952e into main Apr 7, 2026
3 checks passed
@josephjclark josephjclark deleted the feature/1585-fhir-gen-tests branch April 7, 2026 13:52
@josephjclark josephjclark mentioned this pull request Apr 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Closed

Development

Successfully merging this pull request may close these issues.

3 participants