Package com.alibaba.citrus.turbine.auth.impl

Examples of com.alibaba.citrus.turbine.auth.impl.AuthPattern


        }
    }

    @Test
    public void equalsAndHashCode() {
        AuthPattern p1 = new AuthTargetPattern("test");
        AuthPattern p2 = new AuthTargetPattern("/test");
        AuthPattern p3 = new AuthTargetPattern("/*/test");
        AuthPattern p4 = new AuthTargetPattern("/");

        assertEquals(p1, p1);
        assertEquals(p1, p2);
        assertFalse(p1.equals(p3));
        assertFalse(p1.equals(null));
        assertFalse(p1.equals("test"));

        assertEquals(p1.hashCode(), p2.hashCode());
        assertFalse(p1.hashCode() == p3.hashCode());
        assertFalse(p4.hashCode() == p3.hashCode());
    }
View Full Code Here


        }
    }

    @Test
    public void equalsAndHashCode() {
        AuthPattern p1 = new AuthActionPattern("test");
        AuthPattern p2 = new AuthActionPattern("test");
        AuthPattern p3 = new AuthActionPattern("*.test");

        assertEquals(p1, p1);
        assertEquals(p1, p2);
        assertFalse(p1.equals(p3));
        assertFalse(p1.equals(null));
        assertFalse(p1.equals("test"));

        assertEquals(p1.hashCode(), p2.hashCode());
        assertFalse(p1.hashCode() == p3.hashCode());
    }
View Full Code Here

TOP

Related Classes of com.alibaba.citrus.turbine.auth.impl.AuthPattern

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.