Examples of switchToEdit()


Examples of org.xwiki.test.ui.framework.elements.editor.ObjectEditPage.switchToEdit()

        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(
            By.id("Test.EditObjectsTestClass_0_prop"), "choice 3");
        oep.getObjectsOfClass("Test.EditObjectsTestClass").get(0).setFieldValue(
            By.id("Test.EditObjectsTestClass_0_prop"), "choice 4");
        vp = oep.clickSaveAndView();
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.ObjectEditPage.switchToEdit()

        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(
            By.id("Test.EditObjectsTestClass_0_prop"), "this|other");
        vp = oep.clickSaveAndView();
        Assert.assertEquals("this is the content: this other", vp.getContent());
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.ObjectEditPage.switchToEdit()

        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(
            By.id("Test.EditObjectsTestClass_0_prop"), "that|other");
        vp = oep.clickSaveAndView();
        Assert.assertEquals("this is the content: that other", vp.getContent());
    }
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.ObjectEditPage.switchToEdit()

    @Test
    public void testObjectAddAndRemove()
    {
        ObjectEditPage oep = new ObjectEditPage();
        oep.switchToEdit("Test", "EditObjectsTestObject");
        FormElement object = oep.addObject("XWiki.XWikiUsers");
        object.setFieldValue(By.id("XWiki.XWikiUsers_0_first_name"), "John");

        // Add another object
        FormElement object2 = oep.addObject("XWiki.XWikiUsers");
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.ObjectEditPage.switchToEdit()

    @Test
    public void testInlineObjectAddButton()
    {
        ObjectEditPage oep = new ObjectEditPage();
        oep.switchToEdit("Test", "EditObjectsTestObject");
        oep.addObject("XWiki.XWikiUsers");
        oep.addObjectFromInlineLink("XWiki.XWikiUsers");
    }
}
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.WikiEditPage.switchToEdit()

    @Test
    public void testEmptyGroupObjects()
    {
        // Create a doc
        WikiEditPage wep = new WikiEditPage();
        wep.switchToEdit("Test", "EditObjectsTestObject");
        wep.setContent("this is the content");
        ViewPage vp = wep.clickSaveAndView();

        // Add an XWikiGroups object
        ObjectEditPage oep = vp.editObjects();
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.WikiEditPage.switchToEdit()

            "select doc.fullName from XWikiDocument doc where doc.space = 'Test'");
        cep.clickSaveAndView();

        // Create a second page to hold the Object and set its content
        WikiEditPage wep = new WikiEditPage();
        wep.switchToEdit("Test", "EditObjectsTestObject");
        wep.setContent("this is the content");
        ViewPage vp = wep.clickSaveAndView();

        // Add an object of the class created and set the value to be the test page
        ObjectEditPage oep = vp.editObjects();
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.WikiEditPage.switchToEdit()

    @Test
    public void testChangeNumberType()
    {
        // Create class page
        WikiEditPage wep = new WikiEditPage();
        wep.switchToEdit("Test", "EditObjectsTestClass");
        wep.setContent("this is the content");
        ViewPage vp = wep.clickSaveAndView();

        // Add class
        ClassEditPage cep = vp.editClass();
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.WikiEditPage.switchToEdit()

        vp = cep.clickSaveAndView();
        Assert.assertEquals("this is the content", vp.getContent());

        // Create object page
        wep = new WikiEditPage();
        wep.switchToEdit("Test", "EditObjectsTestObject");
        wep.setContent("this is the content: {{velocity}}$doc.display('prop'){{/velocity}}");
        vp = wep.clickSaveAndView();

        // Add object
        ObjectEditPage oep = vp.editObjects();
View Full Code Here

Examples of org.xwiki.test.ui.framework.elements.editor.WikiEditPage.switchToEdit()

    @Test
    public void testChangeListMultipleSelect()
    {
        // Create class page
        WikiEditPage wep = new WikiEditPage();
        wep.switchToEdit("Test", "EditObjectsTestClass");
        wep.setContent("this is the content");
        ViewPage vp = wep.clickSaveAndView();

        // Add class
        ClassEditPage cep = vp.editClass();
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.