New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add tests for OCS upgrade #5337
Add tests for OCS upgrade #5337
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need a BZ for this.
frontend/packages/ceph-storage-plugin/integration-tests/views/upgrade.view.ts
Outdated
Show resolved
Hide resolved
frontend/packages/ceph-storage-plugin/integration-tests/views/upgrade.view.ts
Outdated
Show resolved
Hide resolved
frontend/packages/ceph-storage-plugin/integration-tests/views/upgrade.view.ts
Outdated
Show resolved
Hide resolved
frontend/packages/ceph-storage-plugin/integration-tests/views/upgrade.view.ts
Outdated
Show resolved
Hide resolved
export async function changeCatalogSourceImage(newValue: string) { | ||
const newImageCommand = `oc get -n openshift-marketplace catalogSource ocs-catalogsource -o json|sed 's/ocs-olm-operator:.*\\"/ocs-olm-operator:${newValue}\\"/g'|oc apply -f -`; | ||
await execSync(newImageCommand); | ||
await browser.sleep(5 * MINUTE); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there anything else we can wait on?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I then wait for storage cluster to be in Ready state, but I added this sleep to make sure that waiting doesn't stop too early before the changes are actually applied.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we write a function that checks whether the CR is updated to the required catalogSource. Rather than waiting for 5 minutes for that to happen.
We can take it up in a follow up PR later.
xit('Test channel change from 4.2 to 4.3', async () => { | ||
// Pre-requisites: OCS 4.2 is installed | ||
await changeCatalogSourceImage('latest-stable-4.3.0'); | ||
await changeChannel(channel43); | ||
expect(channelChangeButton.getText()).toEqual(CHANNEL_43); | ||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we require this test?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well, for a very long time this was the only test actually working, before 4.3 to 4.4 upgrade was fixed. I think we can leave it here for now, maybe get rid of it later.
91b84ba
to
b68c347
Compare
b68c347
to
0d73825
Compare
/retest |
0d73825
to
43ecb59
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
export async function changeCatalogSourceImage(newValue: string) { | ||
const newImageCommand = `oc get -n openshift-marketplace catalogSource ocs-catalogsource -o json|sed 's/ocs-olm-operator:.*\\"/ocs-olm-operator:${newValue}\\"/g'|oc apply -f -`; | ||
await execSync(newImageCommand); | ||
await browser.sleep(5 * MINUTE); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we write a function that checks whether the CR is updated to the required catalogSource. Rather than waiting for 5 minutes for that to happen.
We can take it up in a follow up PR later.
/retest Please review the full test history for this PR and help us cut down flakes. |
3 similar comments
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
/retest Please review the full test history for this PR and help us cut down flakes. |
e45e22b
to
83a5159
Compare
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: bipuladh, ebondare The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
No description provided.