mirror of
https://github.com/google/nomulus.git
synced 2025-07-11 21:48:18 +02:00
Replace to(Upper|Lower)Case with Ascii.to$1Case
The presubmits are warning that toUpperCase() and toLowerCase() are locale-specific, and advise using Ascii.toUpperCase() and Ascii.toLowerCase() as a local-invariant alternative. ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=127583677
This commit is contained in:
parent
d9596fa30c
commit
e72491e59b
22 changed files with 62 additions and 38 deletions
|
@ -259,12 +259,12 @@ public class DnsUpdateWriterTest {
|
|||
Update update, String resourceName, int recordType, String... resourceData) {
|
||||
ArrayList<String> expectedData = new ArrayList<>();
|
||||
for (String resourceDatum : resourceData) {
|
||||
expectedData.add(resourceDatum.toLowerCase());
|
||||
expectedData.add(resourceDatum);
|
||||
}
|
||||
|
||||
ArrayList<String> actualData = new ArrayList<>();
|
||||
for (Record record : findUpdateRecords(update, resourceName, recordType)) {
|
||||
actualData.add(record.rdataToString().toLowerCase());
|
||||
actualData.add(record.rdataToString());
|
||||
}
|
||||
assertThat(actualData).containsExactlyElementsIn(expectedData);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue