[
https://issues.apache.org/jira/browse/OAK-6175?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Matt Ryan updated OAK-6175:
---------------------------
Attachment: OAK-6175.patch.4
OAK-6175.patch.3
OAK-6175.patch.2
I tend to agree with the hard-wired locale approach, but I also feel sheepish
for having failed to test for that.
I've attached three new patches, and we can discuss which approach we prefer.
The first patch file, {{OAK-6175.patch.2}}, implements the hard-wired locale
approach, specifying {{Locale.ENGLISH}} as the locale in the
{{String.format()}} used to generate the result.
The second patch file, {{OAK-6175.patch.3}}, expands the test expectations such
that the test will work in whatever locale the code is run. Thus the output
will depend on the locale, but the tests generate expected results also based
on the locale.
The third patch file, {{OAK-6175.patch.4}}, supports a default locale of
{{Locale.ENGLISH}} but also allows passing in a specific locale, and generates
the output based on the locale that is passed in or uses {{Locale.ENGLISH}} if
no locale was provided.
> Add unit test coverage for IOUtils.humanReadableByteCount
> ---------------------------------------------------------
>
> Key: OAK-6175
> URL: https://issues.apache.org/jira/browse/OAK-6175
> Project: Jackrabbit Oak
> Issue Type: Test
> Components: commons
> Reporter: Matt Ryan
> Assignee: Michael Dürig
> Priority: Minor
> Labels: unit-test-missing
> Fix For: 1.7.0, 1.8
>
> Attachments: OAK-6175.patch.1, OAK-6175.patch.2, OAK-6175.patch.3,
> OAK-6175.patch.4
>
>
> There is no unit test coverage for {{IOUtils.humanReadableByteCount}} in
> {{oak-commons}}.
> I will add a patch shortly.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)