Skip to content
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

Added resource validation to MockClient #4559

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

rahul1
Copy link
Member

@rahul1 rahul1 commented May 15, 2024

This PR adds a call to validateResource on the MemoryRepo class, primarily used by MockClient.

This actually discovered a bunch of invalid resources in our preloaded MockClient resources.

Unfortunately, it also meant that we had to revert some of the work from #4286, as this compression created invalid StructureDefinitions that wouldn't validate

@rahul1 rahul1 requested a review from a team as a code owner May 15, 2024 04:17
Copy link

vercel bot commented May 15, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
medplum-provider ✅ Ready (Inspect) Visit Preview 💬 Add feedback May 23, 2024 9:11am
medplum-storybook ✅ Ready (Inspect) Visit Preview 💬 Add feedback May 23, 2024 9:11am
2 Ignored Deployments
Name Status Preview Comments Updated (UTC)
medplum-app ⬜️ Ignored (Inspect) Visit Preview May 23, 2024 9:11am
medplum-www ⬜️ Ignored (Inspect) Visit Preview May 23, 2024 9:11am

@@ -155,60 +161,6 @@ describe('App', () => {
mockServer2.stop();
});

test('Empty endpoint URL', async () => {
Copy link
Member Author

Choose a reason for hiding this comment

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

Removed this test b/c the resource validator prevents Endpoints w/ empty addresses from being created

@rahul1 rahul1 self-assigned this May 15, 2024
@rahul1 rahul1 added the fhir-datastore Related to the FHIR datastore, includes API and FHIR operations label May 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fhir-datastore Related to the FHIR datastore, includes API and FHIR operations
Projects
Status: No status
Development

Successfully merging this pull request may close these issues.

None yet

1 participant