fix: remove deploy messages for environments (#28335)

## Description
PR to remove deploy warnings and messages for environments feature from
the deploy flow

#### PR fixes following issue(s)
Fixes #27485 

#### Type of change

- Bug fix (non-breaking change which fixes an issue)

## Testing
>
#### How Has This Been Tested?
> Please describe the tests that you ran to verify your changes. Also
list any relevant details for your test configuration.
> Delete anything that is not relevant
- [ ] Manual
- [ ] JUnit
- [ ] Jest
- [ ] Cypress
>
>
#### Test Plan
> Add Testsmith test cases links that relate to this PR
>
>
#### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)
>
>
>
## Checklist:
#### Dev activity
- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [ ] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] PR is being merged under a feature flag


#### QA activity:
- [ ] [Speedbreak
features](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#speedbreakers-)
have been covered
- [ ] Test plan covers all impacted features and [areas of
interest](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#areas-of-interest-)
- [ ] Test plan has been peer reviewed by project stakeholders and other
QA members
- [ ] Manually tested functionality on DP
- [ ] We had an implementation alignment call with stakeholders post QA
Round 2
- [ ] Cypress test cases have been added and approved by SDET/manual QA
- [ ] Added `Test Plan Approved` label after Cypress tests were reviewed
- [ ] Added `Test Plan Approved` label after JUnit tests were reviewed
This commit is contained in:
Ayush Pahwa 2023-10-25 22:59:28 +07:00 committed by GitHub
parent 16accbd9ba
commit d80fa0aeee
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 1 additions and 41 deletions

View File

@ -31,9 +31,6 @@ export class DeployMode {
private _backtoHome =
".t--app-viewer-navigation-header .t--app-viewer-back-to-apps-button";
private _homeAppsmithImage = "a.t--appsmith-logo";
public envInfoModal = `[data-testid="t--env-info-modal"]`;
public envInfoModalDismissCheckbox = `[data-testid="t--env-info-dismiss-checkbox"]`;
public envInfoModalDeployButton = `[data-testid="t--env-info-modal-deploy-button"]`;
//refering PublishtheApp from command.js
public DeployApp(
@ -41,8 +38,6 @@ export class DeployMode {
toCheckFailureToast = true,
toValidateSavedState = true,
addDebugFlag = true,
assertEnvInfoModal?: "present" | "absent",
dismissModal = false,
) {
//cy.intercept("POST", "/api/v1/applications/publish/*").as("publishAppli");
@ -53,16 +48,6 @@ export class DeployMode {
this.assertHelper.AssertDocumentReady();
this.StubbingDeployPage(addDebugFlag);
this.agHelper.ClickButton("Deploy");
if (!!assertEnvInfoModal && assertEnvInfoModal === "present") {
this.agHelper.WaitUntilEleAppear(this.envInfoModal);
this.agHelper.AssertElementExist(this.envInfoModal);
if (dismissModal) {
this.agHelper.CheckUncheck(this.envInfoModalDismissCheckbox);
}
} else {
this.agHelper.AssertElementAbsence(this.envInfoModal);
}
this.agHelper.GetNClickIfPresent(this.envInfoModalDeployButton);
this.agHelper.AssertElementAbsence(this.locator._btnSpinner, 10000); //to make sure we have started navigation from Edit page
//cy.get("@windowDeployStub").should("be.calledOnce");
this.assertHelper.AssertDocumentReady();

View File

@ -1,3 +0,0 @@
export function EnvDeployInfoModal() {
return null;
}

View File

@ -1 +0,0 @@
export * from "ce/components/EnvDeployInfoModal";

View File

@ -1,3 +0,0 @@
export function EnvInfoHeader() {
return null;
}

View File

@ -67,8 +67,6 @@ import { useHref } from "./utils";
import { getAppsmithConfigs } from "@appsmith/configs";
import { getIsAppSettingsPaneWithNavigationTabOpen } from "selectors/appSettingsPaneSelectors";
import type { NavigationSetting } from "constants/AppConstants";
import { getUserPreferenceFromStorage } from "@appsmith/utils/Environments";
import { showEnvironmentDeployInfoModal } from "@appsmith/actions/environmentAction";
import CommunityTemplatesPublishInfo from "./CommunityTemplates/Modals/CommunityTemplatesPublishInfo";
import PublishCommunityTemplateModal from "./CommunityTemplates/Modals/PublishCommunityTemplate";
import { useFeatureFlag } from "utils/hooks/useFeatureFlag";
@ -115,9 +113,6 @@ export function EditorHeader() {
const [isPopoverOpen, setIsPopoverOpen] = useState<boolean>(false);
const [showModal, setShowModal] = useState(false);
const isMultipleEnvEnabled = useFeatureFlag(
FEATURE_FLAG.release_datasource_environments_enabled,
);
const [
showPublishCommunityTemplateModal,
setShowPublishCommunityTemplateModal,
@ -176,14 +171,7 @@ export function EditorHeader() {
: "Application name menu (top left)",
});
} else {
if (
!isMultipleEnvEnabled ||
getUserPreferenceFromStorage() === "true"
) {
handlePublish();
} else {
dispatch(showEnvironmentDeployInfoModal());
}
handlePublish();
}
},
[dispatch, handlePublish],

View File

@ -17,7 +17,6 @@ import GitErrorPopup from "../components/GitErrorPopup";
import styled from "styled-components";
import AnalyticsUtil from "utils/AnalyticsUtil";
import { Modal, ModalContent, ModalHeader } from "design-system";
import { EnvInfoHeader } from "@appsmith/components/EnvInfoHeader";
import {
createMessage,
GIT_CONNECTION,
@ -154,7 +153,6 @@ function GitSyncModalV1(props: { isImport?: boolean }) {
<ModalHeader>
{MENU_ITEMS_MAP[activeTabKey]?.modalTitle ?? ""}
</ModalHeader>
{isDeploying && <EnvInfoHeader />}
<Menu
activeTabKey={activeTabKey}
onSelect={(tabKey: string) =>

View File

@ -24,7 +24,6 @@ import {
} from "@appsmith/constants/messages";
import AnalyticsUtil from "utils/AnalyticsUtil";
import { Modal, ModalContent, ModalHeader } from "design-system";
import { EnvInfoHeader } from "@appsmith/components/EnvInfoHeader";
import GitConnectionV2 from "../Tabs/GitConnectionV2";
import GitSettings from "../Tabs/GitSettings";
import { GitSyncModalTab } from "entities/GitSync";
@ -128,7 +127,6 @@ function GitSyncModalV2({ isImport = false }: GitSyncModalV2Props) {
<ModalHeader>
{modalTitle[activeTabKey] || gitMetadata?.repoName}
</ModalHeader>
{isDeploying && <EnvInfoHeader />}
{isGitConnected && <ReconnectSSHError />}
{possibleMenuOptions.includes(activeTabKey) && (
<Menu

View File

@ -42,7 +42,6 @@ import { Spinner } from "design-system";
import SignpostingOverlay from "pages/Editor/FirstTimeUserOnboarding/Overlay";
import { editorInitializer } from "../../utils/editor/EditorUtils";
import { widgetInitialisationSuccess } from "../../actions/widgetActions";
import { EnvDeployInfoModal } from "@appsmith/components/EnvDeployInfoModal";
import urlBuilder from "@appsmith/entities/URLRedirect/URLAssembly";
interface EditorProps {
@ -167,7 +166,6 @@ class Editor extends Component<Props> {
<GlobalHotKeys>
<AppsmithIDE />
<GitSyncModal />
<EnvDeployInfoModal />
<DisconnectGitModal />
<GuidedTourModal />
<RepoLimitExceededErrorModal />