Changeset 8680 in josm for trunk/test/unit/org/openstreetmap
- Timestamp:
- 2015-08-22T21:32:45+02:00 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/unit/org/openstreetmap/josm/data/validation/tests/OpeningHourTestTest.java
r8509 r8680 6 6 import static org.hamcrest.CoreMatchers.is; 7 7 import static org.hamcrest.CoreMatchers.not; 8 import static org.junit.Assert.assertFalse; 8 9 import static org.junit.Assert.assertThat; 10 import static org.junit.Assert.assertTrue; 9 11 10 12 import java.util.Arrays; … … 50 52 assertThat(OPENING_HOUR_TEST.checkOpeningHourSyntax(key, "24/7"), isEmpty()); 51 53 assertThat(OPENING_HOUR_TEST.checkOpeningHourSyntax(key, "Mo-Fr 08:30-20:00"), isEmpty()); 54 assertThat(OPENING_HOUR_TEST.checkOpeningHourSyntax(key, "Mo-Fr sunrise-sunset"), isEmpty()); 52 55 assertThat(OPENING_HOUR_TEST.checkOpeningHourSyntax(key, "09:00-21:00"), isEmpty()); 53 56 assertThat(OPENING_HOUR_TEST.checkOpeningHourSyntax(key, "Su-Th sunset-24:00,04:00-sunrise; Fr-Sa sunset-sunrise"), isEmpty()); … … 57 60 assertThat(OPENING_HOUR_TEST.checkOpeningHourSyntax(key, "Su-Th sunset-24:00, 04:00-sunrise; Fr-Sa sunset-sunrise") 58 61 .get(0).getPrettifiedValue(), is("Su-Th sunset-24:00,04:00-sunrise; Fr-Sa sunset-sunrise")); 62 } 63 64 @Test 65 public void testI18n() throws Exception { 66 assertTrue(OPENING_HOUR_TEST.checkOpeningHourSyntax("opening_hours", ".", OpeningHourTest.CheckMode.POINTS_IN_TIME, false, "de") 67 .get(0).toString().contains("Unerwartetes Zeichen")); 68 assertFalse(OPENING_HOUR_TEST.checkOpeningHourSyntax("opening_hours", ".", OpeningHourTest.CheckMode.POINTS_IN_TIME, false, "en") 69 .get(0).toString().contains("Unerwartetes Zeichen")); 59 70 } 60 71
Note:
See TracChangeset
for help on using the changeset viewer.