Package com.streamreduce.core.service

Examples of com.streamreduce.core.service.UserService


                .roles(userService.getAdminRoles())
                .build();
        user.setAccountOriginator(true);


        UserService mockUserService = mock(UserService.class);
        when(mockUserService.isAliasAvailable(any(Account.class), anyString())).thenReturn(true);
        when(mockUserService.getUserFromSignupKey(anyString(),anyString())).thenReturn(user);
        when(mockUserService.createUser(user)).thenThrow(new InvalidUserAliasException("worst test ever"));

        ReflectionTestUtils.setField(adminUserVerificationResource,"userService",mockUserService);

        Response response = adminUserVerificationResource.completeUserSignupProcess("", new ObjectId().toString(),
                new JSONObjectBuilder()
View Full Code Here


                .roles(userService.getAdminRoles())
                .build();
        user.setAccountOriginator(true);


        UserService mockUserService = mock(UserService.class);
        when(mockUserService.isAliasAvailable(any(Account.class), anyString())).thenReturn(true);
        when(mockUserService.getUserFromInvite(anyString(),anyString())).thenReturn(user);
        when(mockUserService.createUser(user)).thenThrow(new InvalidUserAliasException("worst test ever"));

        ReflectionTestUtils.setField(adminUserVerificationResource,"userService",mockUserService);

        Response response = adminUserVerificationResource.completeUserInviteProcess("", new ObjectId().toString(),
                new JSONObjectBuilder()
View Full Code Here

TOP

Related Classes of com.streamreduce.core.service.UserService

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.