This repository has been archived by the owner on Mar 1, 2024. It is now read-only.
forked from openshift/console
-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'upstream/master' into mergeUpstream_10_…
…03_18_10-07-15 Resolved conflict: - upstream added `dedicated` branding (conflicted with our `okdvirt`)
- Loading branch information
Showing
124 changed files
with
2,673 additions
and
967 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
/* eslint-disable no-undef, no-unused-vars */ | ||
|
||
import { browser, $, element, by, ExpectedConditions as until, Key } from 'protractor'; | ||
import * as _ from 'lodash'; | ||
|
||
import { appHost, checkLogs, checkErrors, testName } from '../protractor.conf'; | ||
import * as crudView from '../views/crud.view'; | ||
|
||
describe('Deploy Image', () => { | ||
afterEach(() => { | ||
checkLogs(); | ||
checkErrors(); | ||
}); | ||
|
||
const appName = 'mysql'; | ||
|
||
describe('Deployment Configs page', () => { | ||
it('has Create button', async() => { | ||
await browser.get(`${appHost}/k8s/ns/${testName}/deploymentconfigs`); | ||
await crudView.isLoaded(); | ||
expect((element(by.buttonText('Create'))).isPresent()).toBe(true); | ||
}); | ||
|
||
it('can be used to navigate to the Deploy Image page', async() => { | ||
await $('#item-create').click().then(() => browser.actions().sendKeys(Key.ARROW_DOWN, Key.ENTER).perform()); | ||
await browser.wait(until.presenceOf($('.co-deploy-image'))); | ||
expect((element(by.cssContainingText('#resource-title', 'Deploy Image'))).isPresent()).toBe(true); | ||
}); | ||
}); | ||
|
||
describe('Deploy Image page', () => { | ||
it('can be used to search for an image', async() => { | ||
await $('#imageName').sendKeys(appName); | ||
await $('.input-group-btn .btn-default').click(); | ||
await browser.wait(until.presenceOf($('.co-image-name-results__details'))); | ||
expect((element(by.cssContainingText('.co-image-name-results__heading', appName))).isPresent()).toBe(true); | ||
}); | ||
|
||
it('can be used to create an app based on an image', async() => { | ||
await $('.co-m-btn-bar .btn-primary').click(); | ||
await browser.wait(until.presenceOf(crudView.actionsDropdown)); | ||
expect(browser.getCurrentUrl()).toContain(`/${appName}`); | ||
expect(crudView.resourceTitle.getText()).toEqual(appName); | ||
}); | ||
}); | ||
|
||
describe('Deploy Image app', () => { | ||
const resources = { | ||
'deploymentconfigs': {kind: 'DeploymentConfig'}, | ||
'imagestreams': {kind: 'ImageStream'}, | ||
'services': {kind: 'Service'}, | ||
}; | ||
|
||
afterAll(async() => { | ||
for (const resource in resources) { | ||
if (resources.hasOwnProperty(resource)) { | ||
const { kind } = resources[resource]; | ||
await crudView.deleteResource(resource, kind, appName); | ||
} | ||
} | ||
}); | ||
|
||
_.each(resources, ({kind}, resource) => { | ||
it(`displays detail view for new ${kind} instance`, async() => { | ||
crudView.checkResourceExists(resource, appName); | ||
}); | ||
}); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.