@Test
public void testUrlDataMatch() {

  assertTrue(urlDataFromStrings("http", "example.com", "", "", "").matchesUrl("http://example.com"));
  assertTrue(urlDataFromStrings("http", "example.com", "", "", "").matchesUrl("http://example.com/"));
  assertFalse(urlDataFromStrings("http", "example.com", "/test", "", "").matchesUrl("http://example.com"));
  assertTrue(urlDataFromStrings("http", "example.com", "/test", "", "").matchesUrl("http://example.com/test"));
  assertFalse(urlDataFromStrings("http", "example.com", "/test", "/*", "").matchesUrl("http://example.com"));
  assertTrue(urlDataFromStrings("http", "example.com", "", "/test", "").matchesUrl("http://example.com/test/other"));
  assertFalse(urlDataFromStrings("http", "example.com", "", "/test", "").matchesUrl("http://example.com/other"));
  assertTrue(urlDataFromStrings("http", "example.com", "", "/test", "/.*").matchesUrl("http://example.com/other"));
  assertTrue(urlDataFromStrings("http", "example.com", "", "", "/.*").matchesUrl("http://example.com/anything"));
  assertTrue(urlDataFromStrings("http", "example.com", "", "", "/.*").matchesUrl("http://example.com/any/thing"));
  assertFalse(urlDataFromStrings("http", "example.com", "", "", "/test/.*").matchesUrl("http://example.com/any/thing"));
}