public void testMatchUserIdExpectsFalse() { LOG.trace("testMatchUserIdExpectsFalse"); Banlist b = this.newBanlist(1, null, null); Assert.assertFalse(b.matches(this.newBanlist(2, null, null))); }
public void testMatchIpExpectsFalse() { LOG.trace("testMatchIpExpectsFalse"); Banlist b = this.newBanlist(0, null, "192.168.1.1"); Assert.assertFalse(b.matches(this.newBanlist(0, null, "192.168.1.2"))); }
public void testMatchEmailExpectsFalse() { LOG.trace("testMatchEmailExpectsFalse"); Banlist b = this.newBanlist(0, "email@1", null); Assert.assertFalse(b.matches(this.newBanlist(0, "email@2", null))); }
public void testMatchIpExpectsTrue() { LOG.trace("testMatchIpExpectsTrue"); Banlist b = this.newBanlist(0, "email@3", "192.168.1.1"); Assert.assertTrue(b.matches(this.newBanlist(0, "email@2", "192.168.1.1"))); }
public void testMatchIpUsingDifferentLengthExpectsFalse() { LOG.trace("testMatchIpUsingDifferentLengthExpectsFalse"); Banlist b = this.newBanlist(0, null, "192.168.7"); Assert.assertFalse(b.matches(this.newBanlist(0, null, "192.168.1.2"))); }
public void testMatchIpUsingStarExpectsFalse2() { LOG.trace("testMatchIpUsingStarExpectsFalse2"); Banlist b = this.newBanlist(0, null, "*.168.7.*"); Assert.assertFalse(b.matches(this.newBanlist(0, null, "172.168.1.2"))); }
public void testMatchIpUsingStarExpectsTrue2() { LOG.trace("testMatchIpUsingStarExpectsTrue2"); Banlist b = this.newBanlist(0, null, "172.*.7.2"); Assert.assertTrue(b.matches(this.newBanlist(0, null, "172.55.7.2"))); }
public void testMatchIpUsingOnlyStarsExpectsFalse() { LOG.trace("testMatchIpUsingOnlyStarsExpectsFalse"); Banlist b = this.newBanlist(0, null, "*.*.*.*"); Assert.assertFalse(b.matches(this.newBanlist(0, null, "172.55.7.2"))); }