Description:
When getting the id for a FshType, rules are checked to see if there is one that will set the id and does not refer to an instance. A value that is not a string will not be valid and not be applied. Therefore, only return the value if it is a string.
Rename test file for FshCodeSystem to match name of source file.
Testing Instructions:
Confirm that using a non-string value in a rule that sets an entity's id does not allow for other rules to fish up that entity using that id. The sample FSH from the issue is an example of this on an Instance:
Instance: requireddataforantimicro-response
InstanceOf: Questionnaire
Usage: #example
* id = 3193360
In this case, an error will be logged for the id rule since it is the wrong type, and there should not be a call stack overflow as described in the linked issue. Behavior should be the same for Profile, Extension, Logical, Resource, CodeSystem, and ValueSet, although these entities will set id using a caret rule, not an assignment rule.
Description: When getting the id for a FshType, rules are checked to see if there is one that will set the id and does not refer to an instance. A value that is not a string will not be valid and not be applied. Therefore, only return the value if it is a string.
Rename test file for FshCodeSystem to match name of source file.
Testing Instructions: Confirm that using a non-string value in a rule that sets an entity's
id
does not allow for other rules to fish up that entity using that id. The sample FSH from the issue is an example of this on an Instance:In this case, an error will be logged for the
id
rule since it is the wrong type, and there should not be a call stack overflow as described in the linked issue. Behavior should be the same for Profile, Extension, Logical, Resource, CodeSystem, and ValueSet, although these entities will setid
using a caret rule, not an assignment rule.Related Issue: Fixes #1519.