Search in sources :

Example 1 with BasicAuthenticationSection

use of org.jboss.tools.openshift.reddeer.wizard.v3.BasicAuthenticationSection 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)

Aggregations

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