Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hey @rsenden,
Here's a summary of changes for the i18n unit test case for your update to resolve issue #1706 .
The primary change what was made:
SharedMessages
resource bundlesub2
and added the previously mentioned option as a Mixin. Also,sub2
has been to use a different resource bundle than the parent command.sub2
command and new Mixin option to the parent commandOther changes that were made so that other existing i18n tests don't break:
SharedMessages_ja
) with description for the new mixin optionstripFactoryInstanceHashcodes
to TestUtil to strip to remove hash codes (object instance IDs?) from trace output so thattestTracingWithResourceBundle
will not fail due to my updates to the test command.expect
string variables for many of the other test cases.One area of concern:
During testing, if there's a parent command that uses a resource bundle where the "usage.header" key is defined, but a subcommand's resource bundle doesn't (and also doesn't have a usage header or description defined in the subcommand's @command annotation) then the subcommand will adopt the "usage.header" key from the parent resource bundle to be used as the subcommand's description when the parent command's help output is displayed. Please see image below:
![image](https://user-images.githubusercontent.com/5297545/173729049-9e6d75ac-432b-457c-8184-1fee7724a1c2.png)
Please let me know if this is expected behavior or if we should instead be expecting to see a blank/emty description of that subcommand from the parent command's help message output. If this is not intended, then for this scenario, I'll update the existing tests to fail if they see anythin for the subcommand's help message output.