Changeset 9853 in josm for trunk/test
- Timestamp:
- 2016-02-23T01:09:36+01:00 (9 years ago)
- Location:
- trunk/test/unit/org/openstreetmap/josm/data/validation
- Files:
-
- 8 added
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/test/unit/org/openstreetmap/josm/data/validation/tests/InternetTagsTest.java
r7937 r9853 31 31 32 32 /** 33 * Test of "Internet Tags" validation test.33 * Test of valid URLs. 34 34 */ 35 35 @Test 36 public void test() { 37 38 // Valid URLs 36 public void testValidUrls() { 39 37 testUrl("url", "www.domain.com", true); // No protocol 40 38 testUrl("url", "http://josm.openstreetmap.de", true); // Simple HTTP … … 47 45 testUrl("website", "http://золотаяцепь.рф", true); // see #10862: IDN URL in Unicode form 48 46 testUrl("website", "http://золотаяцепь.рф/", true); // see #10862: IDN URL in Unicode form + slash 47 testUrl("website", "http://www.dasideenreich.online", true); // see #12257: new TLD added August 19, 2015 48 } 49 49 50 // Invalid URLs 50 /** 51 * Test of invalid URLs. 52 */ 53 @Test 54 public void testInvalidUrls() { 51 55 testUrl("url", "something://www.domain.com", false); // invalid protocol 52 56 testUrl("url", "http://www.domain.invalidtld", false); // invalid TLD 57 } 53 58 54 // Valid E-mails 59 /** 60 * Test of valid e-mails. 61 */ 62 @Test 63 public void testValidEmails() { 55 64 testEmail("email", "contact@www.domain.com", true); // Simple email 56 65 testEmail("contact:email", "john.doe@other-domain.org", true); // Key with : + dash in domain 66 } 57 67 58 // Invalid E-mails 68 /** 69 * Test of invalid e-mails. 70 */ 71 @Test 72 public void testInvalidEmails() { 59 73 testEmail("email", "contact at www.domain.com", false); // No @ 60 74 testEmail("contact:email", "john.doe@other-domain.invalidtld", false); // invalid TLD
Note:
See TracChangeset
for help on using the changeset viewer.