Package org.apache.rave.portal.model.impl

Examples of org.apache.rave.portal.model.impl.AuthorityImpl


    }
   
    @Test
    public void test_getAllDefault() {
        List<Authority> authorities = new ArrayList<Authority>();
        Authority foo = new AuthorityImpl();
        foo.setAuthority("FOO");
        foo.setDefaultForNewUser(true);
        Authority bar = new AuthorityImpl();
        bar.setAuthority("BAR");
        bar.setDefaultForNewUser(true);
       
        authorities.add(foo);
        authorities.add(bar);

        expect(repository.getAllDefault()).andReturn(authorities);
View Full Code Here


    }

    @Test
    public void setAuthenticatedUser_validRole() {
        final User authUser = new UserImpl(USER_ID);
        final Authority userRole = new AuthorityImpl();
        userRole.setAuthority("admin");
        authUser.addAuthority(userRole);
        expect(userRepository.get(USER_ID)).andReturn(authUser).anyTimes();
        replay(userRepository);

        service.setAuthenticatedUser(USER_ID);
View Full Code Here

TOP

Related Classes of org.apache.rave.portal.model.impl.AuthorityImpl

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.