Package org.apache.isis.runtimes.dflt.remoting.common.exchange

Examples of org.apache.isis.runtimes.dflt.remoting.common.exchange.SetAssociationRequest


    @Test
    public void testSetAssociationFailsWithNonCurrentTarget() {
        // version should be different, causing concurrency exception
        movieAdapter.setOptimisticLock(new TestProxyVersion(6));
        try {
            final SetAssociationRequest request =
                new SetAssociationRequest(authenticationSession, "director", movieData, personData);
            server.setAssociation(request);
            fail();
        } catch (final ConcurrencyException expected) {
        }
    }
View Full Code Here


    @Test
    public void testSetAssociationFailsWhenInvisible() {
        nameField.setUpIsVisible(false);
        try {
            final SetAssociationRequest request =
                new SetAssociationRequest(authenticationSession, "director", movieData, personData);
            server.setAssociation(request);
            fail();
        } catch (final IsisException expected) {
            assertEquals("can't modify field as not visible or editable", expected.getMessage());
        }
View Full Code Here

    @Test
    public void testSetAssociationFailsWhenUnavailable() {
        nameField.setUpIsUnusableFor(movieAdapter);
        try {
            final SetAssociationRequest request =
                new SetAssociationRequest(authenticationSession, "director", movieData, personData);
            server.setAssociation(request);
            fail();
        } catch (final IsisException expected) {
            assertEquals("can't modify field as not visible or editable", expected.getMessage());
        }
View Full Code Here

    @Test
    public void testSetAssociationFailsWithNonCurrentAssociate() {
        // version should be different, causing concurrency exception
        personAdapter.setOptimisticLock(new TestProxyVersion(6));
        try {
            final SetAssociationRequest request =
                new SetAssociationRequest(authenticationSession, "director", movieData, personData);
            server.setAssociation(request);
            fail();
        } catch (final ConcurrencyException expected) {
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.isis.runtimes.dflt.remoting.common.exchange.SetAssociationRequest

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.