Examples of clickSaveAndView()


Examples of org.xwiki.test.ui.framework.elements.editor.ClassEditPage.clickSaveAndView()

        // Add class
        ClassEditPage cep = vp.editClass();
        cep.addProperty("prop", "com.xpn.xwiki.objects.classes.NumberClass");
        cep.getNumberClassEditElement("prop").setNumberType("integer");
        vp = cep.clickSaveAndView();
        Assert.assertEquals("this is the content", vp.getContent());

        // Create object page
        wep = new WikiEditPage();
        wep.switchToEdit("Test", "EditObjectsTestObject");
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.ClassEditPage.clickSaveAndView()

        // Change number to double type
        cep = new ClassEditPage();
        cep.switchToEdit("Test", "EditObjectsTestClass");
        cep.getNumberClassEditElement("prop").setNumberType("double");
        vp = cep.clickSaveAndView();
        Assert.assertEquals("this is the content", vp.getContent());

        // Verify conversion
        oep = new ObjectEditPage();
        oep.switchToEdit("Test", "EditObjectsTestObject");
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.ClassEditPage.clickSaveAndView()

        // Change number to long type
        cep = new ClassEditPage();
        cep.switchToEdit("Test", "EditObjectsTestClass");
        cep.getNumberClassEditElement("prop").setNumberType("long");
        vp = cep.clickSaveAndView();
        Assert.assertEquals("this is the content", vp.getContent());

        // Verify conversion
        oep = new ObjectEditPage();
        oep.switchToEdit("Test", "EditObjectsTestObject");
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.ClassEditPage.clickSaveAndView()

        ClassEditPage cep = vp.editClass();
        cep.addProperty("prop", "com.xpn.xwiki.objects.classes.StaticListClass");
        StaticListClassEditElement slcee = cep.getStaticListClassEditElement("prop");
        slcee.setMultiSelect(false);
        slcee.setValues("choice 1|choice 2|choice 3|choice 4|choice 5");
        vp = cep.clickSaveAndView();
        Assert.assertEquals("this is the content", vp.getContent());

        // Create object page
        wep = new WikiEditPage();
        wep.switchToEdit("Test", "EditObjectsTestObject");
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.ClassEditPage.clickSaveAndView()

        // Change list to a multiple select.
        cep = new ClassEditPage();
        cep.switchToEdit("Test", "EditObjectsTestClass");
        cep.getStaticListClassEditElement("prop").setMultiSelect(true);
        vp = cep.clickSaveAndView();
        Assert.assertEquals("this is the content", vp.getContent());

        // Verify conversion
        oep.switchToEdit("Test", "EditObjectsTestObject");
        oep.getObjectsOfClass("Test.EditObjectsTestClass").get(0).setFieldValue(
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.ClassEditPage.clickSaveAndView()

        ClassEditPage cep = vp.editClass();
        cep.addProperty("prop", "com.xpn.xwiki.objects.classes.StaticListClass");
        StaticListClassEditElement slcee = cep.getStaticListClassEditElement("prop");
        slcee.setMultiSelect(true);
        slcee.setDisplayType(StaticListClassEditElement.DisplayType.INPUT);
        vp = cep.clickSaveAndView();
        Assert.assertEquals("this is the content", vp.getContent());

        // Create object page
        wep = new WikiEditPage();
        wep.switchToEdit("Test", "EditObjectsTestObject");
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.ClassEditPage.clickSaveAndView()

        // Change list to relational storage.
        cep = new ClassEditPage();
        cep.switchToEdit("Test", "EditObjectsTestClass");
        cep.getStaticListClassEditElement("prop").setRelationalStorage(true);
        vp = cep.clickSaveAndView();
        Assert.assertEquals("this is the content", vp.getContent());

        // Make sure we can still edit the object.
        oep.switchToEdit("Test", "EditObjectsTestObject");
        oep.getObjectsOfClass("Test.EditObjectsTestClass").get(0).setFieldValue(
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.ClassEditPage.clickSaveAndView()

        // Change list to non-relational storage.
        cep = new ClassEditPage();
        cep.switchToEdit("Test", "EditObjectsTestClass");
        cep.getStaticListClassEditElement("prop").setRelationalStorage(false);
        vp = cep.clickSaveAndView();
        Assert.assertEquals("this is the content", vp.getContent());

        // Make sure we can still edit the object.
        oep.switchToEdit("Test", "EditObjectsTestObject");
        oep.getObjectsOfClass("Test.EditObjectsTestClass").get(0).setFieldValue(
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.ClassEditPage.clickSaveAndView()

        // least once to ensure the UI works).
        ClassEditPage cep = getUtil().gotoPage("Test", "EditObjectsTestClass").editClass();

        // Create a class with a string property
        cep.addProperty("prop", "com.xpn.xwiki.objects.classes.StringClass");
        cep.clickSaveAndView();

        // Create object page
        ViewPage vp = getUtil().createPage("Test", "EditObjectsTestObject",
            "this is the content: {{velocity}}$doc.display('prop'){{/velocity}}", getTestMethodName());
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.ClassEditPage.clickSaveAndView()

        Assert.assertEquals("this is the content: testing value 1/testing value 2/testing value 1", vp.getContent());

        // Delete the first property from the class
        ClassEditPage cep = getUtil().editClass("Test", "EditObjectsTestClass");
        cep.deleteProperty("prop1");
        cep.clickSaveAndView();

        vp = getUtil().gotoPage("Test", "EditObjectsTestObject");
        Assert.assertEquals("this is the content: /testing value 2/testing value 1", vp.getContent());

        oep = vp.editObjects();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.