Skip to content

Commit

Permalink
consider PendingChartCreation as part of upgrade process (#4544)
Browse files Browse the repository at this point in the history
  • Loading branch information
Craig O'Donnell authored Apr 11, 2024
1 parent 9d84ee7 commit 8685861
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 13 deletions.
3 changes: 2 additions & 1 deletion web/src/utilities/utilities.js
Original file line number Diff line number Diff line change
Expand Up @@ -681,7 +681,8 @@ export const Utilities = {
const normalizedState = this.clusterState(cluster.state);
if (
normalizedState === "Upgrading" ||
normalizedState === "Upgrading addons"
normalizedState === "Upgrading addons" ||
normalizedState === "Creating addons"
) {
return true;
}
Expand Down
32 changes: 20 additions & 12 deletions web/src/utilities/utilities.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,20 +85,28 @@ describe("Utilities", () => {
});

it("should return true if the user has tried to deploy the current version and a cluster upgrade is in progress", () => {
const apps = [
{
downstream: {
currentVersion: {
status: "deployed",
},
cluster: {
requiresUpgrade: true,
state: "Installing",
for (const installationState of [
"CopyingArtifacts",
"Enqueued",
"Installing",
"AddonsInstalling",
"PendingChartCreation",
]) {
const apps = [
{
downstream: {
currentVersion: {
status: "deployed",
},
cluster: {
requiresUpgrade: true,
state: installationState,
},
},
},
},
];
expect(Utilities.shouldShowClusterUpgradeModal(apps)).toBe(true);
];
expect(Utilities.shouldShowClusterUpgradeModal(apps)).toBe(true);
}
});

it("should return false if there are is one installation that does not have a state", () => {
Expand Down

0 comments on commit 8685861

Please sign in to comment.