Package org.eurekastreams.commons.actions.context.service

Examples of org.eurekastreams.commons.actions.context.service.ServiceActionContext


                will(returnValue(undeletedGadget));

                allowing(deleteCacheKeysMapper).execute(with(any(Set.class)));
            }
        });
        ServiceActionContext currentContext = new ServiceActionContext(new Long(GADGET_ID), principalMock);
        sut.execute(currentContext);
        context.assertIsSatisfied();
    }
View Full Code Here


        });

        Map<String, String> errors = null;
        try
        {
            ServiceActionContext currentContext = new ServiceActionContext(request, principalMock);
            sut.validate(currentContext);
        }
        catch (ValidationException vex)
        {
            errors = vex.getErrors();
View Full Code Here

                oneOf(tabMapper).undeleteGadget(GADGET_ID);
                will(throwException(new GadgetUndeletionException("Error undeleting", GADGET_ID)));
            }
        });
        ServiceActionContext currentContext = new ServiceActionContext(new Long(GADGET_ID), principalMock);
        sut.execute(currentContext);
        context.assertIsSatisfied();
    }
View Full Code Here

        });

        Map<String, String> errors = null;
        try
        {
            ServiceActionContext currentContext = new ServiceActionContext(request, principalMock);
            sut.validate(currentContext);
        }
        catch (ValidationException vex)
        {
            errors = vex.getErrors();
View Full Code Here

                oneOf(domainGroupMapperMock).fetchUniqueResult(with(any(String.class)));
                will(returnValue(testTarget));
            }
        });

        ServiceActionContext currentContext = new ServiceActionContext(request, principalMock);
        sut.validate(currentContext);

        context.assertIsSatisfied();
    }
View Full Code Here

                oneOf(domainGroupMapperMock).fetchUniqueResult(with(any(String.class)));
                will(returnValue(null));
            }
        });

        ServiceActionContext currentContext = new ServiceActionContext(request, principalMock);
        sut.validate(currentContext);

        context.assertIsSatisfied();
    }
View Full Code Here

                oneOf(domainGroupMapperMock).fetchUniqueResult(with(any(String.class)));
                will(returnValue(null));
            }
        });

        ServiceActionContext currentContext = new ServiceActionContext(request, principalMock);
        sut.validate(currentContext);

        context.assertIsSatisfied();
    }
View Full Code Here

        ActivityDTO currentActivity = PostActivityTestHelpers.buildActivityDTO(
                PostActivityTestHelpers.DestinationStreamTestState.VALID, false, testComment, DESTINATION_ID);

        currentRequest = new PostActivityRequest(currentActivity);

        currentActionContext = new ServiceActionContext(currentRequest, currentPrincipal);

        context.checking(new Expectations()
        {
            {
                oneOf(postVerbValMock).validate(with(any(ActivityDTO.class)));
View Full Code Here

    {
        ActivityDTO currentActivity = PostActivityTestHelpers.buildActivityDTO(
                PostActivityTestHelpers.DestinationStreamTestState.VALID, true, testComment, DESTINATION_ID);

        currentRequest = new PostActivityRequest(currentActivity);
        currentActionContext = new ServiceActionContext(currentRequest, currentPrincipal);

        sut.validate(currentActionContext);
        context.assertIsSatisfied();
    }
View Full Code Here

    {
        ActivityDTO currentActivity = PostActivityTestHelpers.buildActivityDTO(
                PostActivityTestHelpers.DestinationStreamTestState.VALID, false, testComment, DESTINATION_ID);

        currentRequest = new PostActivityRequest(currentActivity);
        currentActionContext = new ServiceActionContext(currentRequest, currentPrincipal);

        context.checking(new Expectations()
        {
            {
                oneOf(postVerbValMock).validate(with(any(ActivityDTO.class)));
View Full Code Here

TOP

Related Classes of org.eurekastreams.commons.actions.context.service.ServiceActionContext

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.