diff --git a/web/src/utilities/utilities.js b/web/src/utilities/utilities.js index ec0c27a6c6..3c8f189c1d 100644 --- a/web/src/utilities/utilities.js +++ b/web/src/utilities/utilities.js @@ -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; } diff --git a/web/src/utilities/utilities.test.js b/web/src/utilities/utilities.test.js index 5911813c05..12d4ea9028 100644 --- a/web/src/utilities/utilities.test.js +++ b/web/src/utilities/utilities.test.js @@ -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", () => {