aboutsummaryrefslogtreecommitdiffstats
path: root/lint/libs/lint_checks/tests/src/com/android/tools/lint/checks/data/bytecode/LocaleTest.java.txt
diff options
context:
space:
mode:
Diffstat (limited to 'lint/libs/lint_checks/tests/src/com/android/tools/lint/checks/data/bytecode/LocaleTest.java.txt')
-rw-r--r--lint/libs/lint_checks/tests/src/com/android/tools/lint/checks/data/bytecode/LocaleTest.java.txt37
1 files changed, 0 insertions, 37 deletions
diff --git a/lint/libs/lint_checks/tests/src/com/android/tools/lint/checks/data/bytecode/LocaleTest.java.txt b/lint/libs/lint_checks/tests/src/com/android/tools/lint/checks/data/bytecode/LocaleTest.java.txt
deleted file mode 100644
index 3c60c9d..0000000
--- a/lint/libs/lint_checks/tests/src/com/android/tools/lint/checks/data/bytecode/LocaleTest.java.txt
+++ /dev/null
@@ -1,37 +0,0 @@
-package test.pkg;
-
-import java.text.*;
-import java.util.*;
-
-public class LocaleTest {
- public void testStrings() {
- System.out.println("OK".toUpperCase(Locale.getDefault()));
- System.out.println("OK".toUpperCase(Locale.US));
- System.out.println("OK".toUpperCase(Locale.CHINA));
- System.out.println("WRONG".toUpperCase());
-
- System.out.println("OK".toLowerCase(Locale.getDefault()));
- System.out.println("OK".toLowerCase(Locale.US));
- System.out.println("OK".toLowerCase(Locale.CHINA));
- System.out.println("WRONG".toLowerCase());
-
- String.format(Locale.getDefault(), "OK: %f", 1.0f);
- String.format("OK: %x %A %c %b %B %h %n %%", 1, 2, 'c', true, false, 5);
- String.format("WRONG: %f", 1.0f); // Implies locale
- String.format("WRONG: %1$f", 1.0f);
- String.format("WRONG: %e", 1.0f);
- String.format("WRONG: %d", 1.0f);
- String.format("WRONG: %g", 1.0f);
- String.format("WRONG: %g", 1.0f);
- String.format("WRONG: %1$tm %1$te,%1$tY",
- new GregorianCalendar(2012, GregorianCalendar.AUGUST, 27));
- }
-
- @android.annotation.SuppressLint("NewApi") // DateFormatSymbols requires API 9
- public void testSimpleDateFormat() {
- new SimpleDateFormat(); // WRONG
- new SimpleDateFormat("yyyy-MM-dd"); // WRONG
- new SimpleDateFormat("yyyy-MM-dd", DateFormatSymbols.getInstance()); // WRONG
- new SimpleDateFormat("yyyy-MM-dd", Locale.US); // OK
- }
-}