Examples of ExtensionPane


Examples of org.xwiki.extension.test.po.ExtensionPane

        // Make sure the new version is installed.
        getExtensionTestUtils().install(new ExtensionId(extensionId, newVersion));

        // Downgrade the extension.
        ExtensionAdministrationPage adminPage = ExtensionAdministrationPage.gotoPage().clickAddExtensionsSection();
        ExtensionPane extensionPane =
            adminPage.getSearchBar().clickAdvancedSearch().search(extensionId, oldVersion).getExtension(0);
        Assert.assertEquals("remote-installed", extensionPane.getStatus());
        Assert.assertEquals("Version 2.1.4 is installed", extensionPane.getStatusMessage());
        extensionPane = extensionPane.downgrade();

        // Check the downgrade plan.
        List<DependencyPane> downgradePlan = extensionPane.openProgressSection().getJobPlan();
        Assert.assertEquals(1, downgradePlan.size());
        Assert.assertEquals(extensionId, downgradePlan.get(0).getName());
        Assert.assertEquals(oldVersion, downgradePlan.get(0).getVersion());
        Assert.assertEquals("remote-installed", downgradePlan.get(0).getStatus());
        Assert.assertEquals("Version 2.1.4 is installed", downgradePlan.get(0).getStatusMessage());

        // Finish the downgrade and check the downgrade log.
        extensionPane = extensionPane.confirm();
        Assert.assertEquals("installed", extensionPane.getStatus());
        Assert.assertEquals("Installed", extensionPane.getStatusMessage());
        List<LogItemPane> log = extensionPane.openProgressSection().getJobLog();
        Assert.assertTrue(log.size() > 2);
        Assert.assertEquals("info", log.get(2).getLevel());
        Assert.assertEquals("Resolving extension [alice-xar-extension 1.3] on namespace [Home]", log.get(2)
            .getMessage());
        Assert.assertEquals("info", log.get(log.size() - 1).getLevel());
View Full Code Here

Examples of org.xwiki.extension.test.po.ExtensionPane

        TestExtension extension = getRepositoryTestUtils().getTestExtension(extensionId, "jar");
        getRepositoryTestUtils().addExtension(extension);

        // Search the extension and install it.
        ExtensionAdministrationPage adminPage = ExtensionAdministrationPage.gotoPage().clickAddExtensionsSection();
        ExtensionPane extensionPane =
            adminPage.getSearchBar().clickAdvancedSearch().search(extensionId).getExtension(0);
        extensionPane.install().confirm();

        // Check the result.
        Assert.assertEquals("Hello world! Hello XWiki!", getUtil().gotoPage(getTestClassName(), getTestMethodName())
            .getContent());
    }
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.