Search in sources :

Example 1 with OpenShift3ConnectionWizard

use of org.jboss.tools.openshift.reddeer.wizard.v3.OpenShift3ConnectionWizard in project jbosstools-openshift by jbosstools.

the class CreateNewConnectionTest method testCreateNewV3BasicConnection.

@Test
@RunIf(conditionClass = ConnectionCredentialsExists.class)
public void testCreateNewV3BasicConnection() {
    OpenShiftExplorerView explorer = new OpenShiftExplorerView();
    explorer.open();
    DatastoreOS3.AUTH_METHOD = AuthenticationMethod.BASIC;
    explorer.openConnectionShell();
    OpenShift3ConnectionWizard connectionWizard = new OpenShift3ConnectionWizard();
    connectionWizard.setServer(DatastoreOS3.SERVER);
    connectionWizard.switchAuthenticationSection(DatastoreOS3.AUTH_METHOD);
    BasicAuthenticationSection authSection = (BasicAuthenticationSection) connectionWizard.getAuthSection();
    authSection.setUsername(DatastoreOS3.USERNAME);
    authSection.setPassword(DatastoreOS3.PASSWORD);
    authSection.setSavePassword(false);
    connectionWizard.finishAndHandleCertificate();
    assertTrue("Connection does not exist in OpenShift Explorer view", explorer.connectionExists(DatastoreOS3.USERNAME));
}
Also used : OpenShift3ConnectionWizard(org.jboss.tools.openshift.reddeer.wizard.v3.OpenShift3ConnectionWizard) BasicAuthenticationSection(org.jboss.tools.openshift.reddeer.wizard.v3.BasicAuthenticationSection) OpenShiftExplorerView(org.jboss.tools.openshift.reddeer.view.OpenShiftExplorerView) RunIf(org.eclipse.reddeer.junit.execution.annotation.RunIf) AbstractTest(org.jboss.tools.openshift.ui.bot.test.application.v3.basic.AbstractTest) Test(org.junit.Test)

Example 2 with OpenShift3ConnectionWizard

use of org.jboss.tools.openshift.reddeer.wizard.v3.OpenShift3ConnectionWizard in project jbosstools-openshift by jbosstools.

the class OpenShift3Connection method editConnection.

public OpenShift3ConnectionWizard editConnection() {
    activateOpenShiftExplorerView();
    new ContextMenuItem(getTreeItem(), OpenShiftLabel.ContextMenu.EDIT_CONNECTION).select();
    return new OpenShift3ConnectionWizard(OpenShiftLabel.Shell.EDIT_CONNECTION);
}
Also used : OpenShift3ConnectionWizard(org.jboss.tools.openshift.reddeer.wizard.v3.OpenShift3ConnectionWizard) ContextMenuItem(org.eclipse.reddeer.swt.impl.menu.ContextMenuItem)

Aggregations

OpenShift3ConnectionWizard (org.jboss.tools.openshift.reddeer.wizard.v3.OpenShift3ConnectionWizard)2 RunIf (org.eclipse.reddeer.junit.execution.annotation.RunIf)1 ContextMenuItem (org.eclipse.reddeer.swt.impl.menu.ContextMenuItem)1 OpenShiftExplorerView (org.jboss.tools.openshift.reddeer.view.OpenShiftExplorerView)1 BasicAuthenticationSection (org.jboss.tools.openshift.reddeer.wizard.v3.BasicAuthenticationSection)1 AbstractTest (org.jboss.tools.openshift.ui.bot.test.application.v3.basic.AbstractTest)1 Test (org.junit.Test)1