Package com.jboss.dvd.seam

Examples of com.jboss.dvd.seam.ShoppingCart


                invokeAction("#{search.addToCart}");
            }
           
            @Override
            protected void renderResponse() throws Exception {
                ShoppingCart cart = (ShoppingCart) getValue("#{cart}");
                assert cart != null;
                assert cart.getCart().size() == 1;
            }
        }.run();
       
        new FacesRequest("/dvd.xhtml", id) {
            @Override
            protected void beforeRequest() {
                setParameter("id", "42");
            }         
        }.run();
       
        new FacesRequest("/dvd.xhtml", id) {
            @Override
            protected void invokeApplication() throws Exception {
                invokeAction("#{search.addToCart}");
            }
           
            @Override
            protected void renderResponse() throws Exception {
                ShoppingCart cart = (ShoppingCart) getValue("#{cart}");
                assert cart != null;
                assert cart.getCart().size() == 2;
            }
        }.run();
       
        new FacesRequest("/dvd.xhtml", id) {
            @Override
            protected void beforeRequest() {
                setParameter("id", "41");
            }        
        }.run();
       
        new FacesRequest("/dvd.xhtml", id) {
            @Override
            protected void invokeApplication() throws Exception {
                invokeAction("#{search.addToCart}");
            }
           
            @Override
            protected void renderResponse() throws Exception {
                ShoppingCart cart = (ShoppingCart) getValue("#{cart}");
                assert cart != null;
                assert cart.getCart().size() == 2;
            }
        }.run();
       
       
        new FacesRequest("/dvd.xhtml", id) {
            @Override
            protected void beforeRequest() {
                setParameter("id", "43");
            }          
        }.run();
       
        new FacesRequest("/dvd.xhtml", id) {
            @Override
            protected void invokeApplication() throws Exception {
                invokeAction("#{search.addToCart}");
            }
           
            @Override
            protected void renderResponse() throws Exception {
                ShoppingCart cart = (ShoppingCart) getValue("#{cart}");
                assert cart != null;
                assert cart.getCart().size() == 3;
            }
        }.run();
       
    }
View Full Code Here

TOP

Related Classes of com.jboss.dvd.seam.ShoppingCart

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.