-
Notifications
You must be signed in to change notification settings - Fork 522
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
Adds a local copy of the npm packages for the validator #3241
base: main
Are you sure you want to change the base?
Conversation
src/Microsoft.Health.Fhir.R4.Api/Microsoft.Health.Fhir.R4.Api.csproj
Outdated
Show resolved
Hide resolved
src/Microsoft.Health.Fhir.R4B.Api/Microsoft.Health.Fhir.R4B.Api.csproj
Outdated
Show resolved
Hide resolved
src/Microsoft.Health.Fhir.R5.Api/Microsoft.Health.Fhir.R5.Api.csproj
Outdated
Show resolved
Hide resolved
src/Microsoft.Health.Fhir.Stu3.Api/Microsoft.Health.Fhir.Stu3.Api.csproj
Outdated
Show resolved
Hide resolved
src/Microsoft.Health.Fhir.Shared.Core/Features/Validation/ProfileValidator.cs
Outdated
Show resolved
Hide resolved
src/Microsoft.Health.Fhir.Shared.Core/Features/Validation/ProfileValidator.cs
Show resolved
Hide resolved
throw; | ||
} | ||
} | ||
|
||
internal static (string Server, string CorePackageName, string ExpansionsPackageName) GetFhirPackageVariables() | ||
{ | ||
Type type = typeof(FhirPackageSource); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Where is this coming from? I can't find reference to this FhirPackageSource or where its fields are defined.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are compiled into the Firely libraries, it isn't a great dependency, but its a way to find the NPM urls. Perhaps we should define these ourselves?
There is a unit test to cover they exist: https://github.com/microsoft/fhir-server/pull/3241/files#diff-98805c9eb649d4044301a52d69bb13b1e09768a441ded93ce851277986c8103aR18
<Content Include="hl7.fhir.r4.core-4.0.1.tgz"> | ||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> | ||
</Content> | ||
<Content Include="hl7.fhir.r4.elements-4.0.1.tgz"> | ||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> | ||
</Content> | ||
<Content Include="hl7.fhir.r4.expansions-4.0.1.tgz"> | ||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory> | ||
</Content> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we be checking these into OSS?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a good question. Previously we did reference the specification.zip file, which was part of the nuget that we were using. This is the same content, but in this case we are including the package in our repo.
public async void GivenAValidateByIdRequest_WhenTheResourceIsValid_ThenAnOkMessageIsReturned() | ||
{ | ||
Skip.If(ModelInfoProvider.Instance.Version == FhirSpecification.R5, "Validation not currently working correctly for R5"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A little scared of doing this. It isn't an R5 thing, its a Firely package thing. Can we skip if Hl7.FHIR packages <= version x.x.x?
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
Description
Add a local copy of the NPM packages for the validator.
Related issues
Addresses [issue #].
Testing
Describe how this change was tested.
FHIR Team Checklist
Semver Change (docs)
Patch|Skip|Feature|Breaking (reason)