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

Fix FSHRunner command execution #714

Merged
merged 2 commits into from
Jun 28, 2023
Merged

Conversation

dotasek
Copy link
Collaborator

@dotasek dotasek commented Jun 22, 2023

Command execution should use CommandLine to construct arguments rather than concatenating Strings

@dotasek
Copy link
Collaborator Author

dotasek commented Jun 28, 2023

In addition to the added unit tests, this refactor was also tested locally on Mac and on Windows by running against the https://github.com/HL7/fhir-sdoh-clinicalcare IG.

The following CLI params were used in order to emulate conditions similar to both the auto-ig-builder and local developer execution:

java -jar org.hl7.fhir.publisher.cli-1.3.20-refactor.jar -ig /IGS/fhir-sdoh-clinicalcare > ig-build.refactor.log

java -jar org.hl7.fhir.publisher.cli-1.3.20-refactor.jar -ig /IGS/fhir-sdoh-clinicalcare-w-fsh-ini > ig-build-w-fsh-ini.refactor.log

java -jar org.hl7.fhir.publisher.cli-1.3.20-refactor.jar -auto-ig-build -ig /IGS/fhir-sdoh-clinicalcare > ig-build-auto-ig-build.refactor.log

java -jar org.hl7.fhir.publisher.cli-1.3.20-refactor.jar -auto-ig-build -ig /IGS/fhir-sdoh-clinicalcare-w-fsh-ini > ig-build-auto-ig-build-w-fsh-ini.refactor.log

The fhir-sdoh-clinicalcare-w-fsh-ini directory was an exact copy of the original IG with the following fhs.ini file added:

[FSH]
sushi-version=3.0.0

All runs excuted as expected with the correct --require-latest param visible for -auto-ig-build runs, and the following output consistently produced:

Sushi: ========================= SUSHI RESULTS ===========================       (02:00.332)
Sushi: |  -------------------------------------------------------------  |       (02:00.332)
Sushi: | |    Profiles   |  Extensions  |   Logicals   |   Resources   | |       (02:00.332)
Sushi: | |-------------------------------------------------------------| |       (02:00.332)
Sushi: | |      19       |      2       |      0       |       0       | |       (02:00.332)
Sushi: |  -------------------------------------------------------------  |       (02:00.333)
Sushi: |  -------------------------------------------------------------  |       (02:00.333)
Sushi: | |      ValueSets     |    CodeSystems    |     Instances      | |       (02:00.333)
Sushi: | |-------------------------------------------------------------| |       (02:00.333)
Sushi: | |         14         |         1         |         67         | |       (02:00.333)
Sushi: |  -------------------------------------------------------------  |       (02:00.333)
Sushi: |                                                                 |       (02:00.333)
Sushi: ===================================================================       (02:00.333)
Sushi: | You should mullet over.                0 Errors      5 Warnings |       (02:00.333)
Sushi: ===================================================================       (02:00.333)
Sushi: 

@dotasek dotasek merged commit 95e2a5d into master Jun 28, 2023
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant