From eab3cedf00443540c3616cb5a63bbe64c921e881 Mon Sep 17 00:00:00 2001 From: Andrew Gable Date: Tue, 4 Jun 2024 08:44:22 -0600 Subject: [PATCH] Revert "Add HybridApp deploy when we deploy staging" --- .github/workflows/platformDeploy.yml | 10 ---------- .../assertions/platformDeployAssertions.ts | 13 ------------- workflow_tests/mocks/platformDeployMocks.ts | 5 ----- workflow_tests/platformDeploy.test.ts | 6 ------ 4 files changed, 34 deletions(-) diff --git a/.github/workflows/platformDeploy.yml b/.github/workflows/platformDeploy.yml index bb24a1be5e5c..353a898a941f 100644 --- a/.github/workflows/platformDeploy.yml +++ b/.github/workflows/platformDeploy.yml @@ -352,16 +352,6 @@ jobs: env: CF_API_KEY: ${{ secrets.CLOUDFLARE_TOKEN }} - # Build a version of iOS and Android HybridApp if we are deploying to staging - hybridApp: - runs-on: ubuntu-latest - needs: validateActor - if: ${{ fromJSON(needs.validateActor.outputs.IS_DEPLOYER) }} - steps: - - name: 'Deploy HybridApp' - if: ${{ !fromJSON(env.SHOULD_DEPLOY_PRODUCTION) }} - uses: Expensify/Mobile-Deploy/.github/workflows/deploy.yml@main - postSlackMessageOnFailure: name: Post a Slack message when any platform fails to build or deploy runs-on: ubuntu-latest diff --git a/workflow_tests/assertions/platformDeployAssertions.ts b/workflow_tests/assertions/platformDeployAssertions.ts index c92d3dda97d0..24bb91f001f6 100644 --- a/workflow_tests/assertions/platformDeployAssertions.ts +++ b/workflow_tests/assertions/platformDeployAssertions.ts @@ -376,18 +376,6 @@ function assertPostGithubCommentJobExecuted(workflowResult: Step[], didExecute = }); } -function assertHybridAppJobExecuted(workflowResult: Step[], didExecute = true) { - const steps = [createStepAssertion('Deploy HybridApp', true, null, 'HYBRID_APP', 'Deploy HybridApp')] as const; - - steps.forEach((expectedStep) => { - if (didExecute) { - expect(workflowResult).toEqual(expect.arrayContaining([expectedStep])); - } else { - expect(workflowResult).not.toEqual(expect.arrayContaining([expectedStep])); - } - }); -} - export default { assertVerifyActorJobExecuted, assertDeployChecklistJobExecuted, @@ -395,7 +383,6 @@ export default { assertDesktopJobExecuted, assertIOSJobExecuted, assertWebJobExecuted, - assertHybridAppJobExecuted, assertPostSlackOnFailureJobExecuted, assertPostSlackOnSuccessJobExecuted, assertPostGithubCommentJobExecuted, diff --git a/workflow_tests/mocks/platformDeployMocks.ts b/workflow_tests/mocks/platformDeployMocks.ts index ca6e05b57f8e..9d5727bbf5f5 100644 --- a/workflow_tests/mocks/platformDeployMocks.ts +++ b/workflow_tests/mocks/platformDeployMocks.ts @@ -199,10 +199,6 @@ const PLATFORM_DEPLOY__WEB__STEP_MOCKS = [ PLATFORM_DEPLOY__WEB__PURGE_STAGING_CACHE__STEP_MOCK, ]; -// deploy hybridApp -const PLATFORM_DEPLOY__HYBRID_APP__STEP_MOCK = createMockStep('Deploy HybridApp', 'Deploy HybridApp', 'HYBRID_APP'); -const PLATFORM_DEPLOY__HYBRID_APP__STEP_MOCKS = [PLATFORM_DEPLOY__HYBRID_APP__STEP_MOCK]; - // post slack message on failure const PLATFORM_DEPLOY__POST_SLACK_FAIL__POST_SLACK__STEP_MOCK = createMockStep('Post Slack message on failure', 'Posting Slack message on platform deploy failure', 'POST_SLACK_FAIL', [ 'SLACK_WEBHOOK', @@ -278,7 +274,6 @@ export default { PLATFORM_DEPLOY__DESKTOP__STEP_MOCKS, PLATFORM_DEPLOY__IOS__STEP_MOCKS, PLATFORM_DEPLOY__WEB__STEP_MOCKS, - PLATFORM_DEPLOY__HYBRID_APP__STEP_MOCKS, PLATFORM_DEPLOY__POST_SLACK_FAIL__STEP_MOCKS, PLATFORM_DEPLOY__POST_SLACK_SUCCESS__STEP_MOCKS, PLATFORM_DEPLOY__POST_GITHUB_COMMENT__STEP_MOCKS, diff --git a/workflow_tests/platformDeploy.test.ts b/workflow_tests/platformDeploy.test.ts index 98fd9b933df4..0ac68eb6d55b 100644 --- a/workflow_tests/platformDeploy.test.ts +++ b/workflow_tests/platformDeploy.test.ts @@ -101,7 +101,6 @@ describe('test workflow platformDeploy', () => { desktop: mocks.PLATFORM_DEPLOY__DESKTOP__STEP_MOCKS, iOS: mocks.PLATFORM_DEPLOY__IOS__STEP_MOCKS, web: mocks.PLATFORM_DEPLOY__WEB__STEP_MOCKS, - hybridApp: mocks.PLATFORM_DEPLOY__HYBRID_APP__STEP_MOCKS, postSlackMessageOnFailure: mocks.PLATFORM_DEPLOY__POST_SLACK_FAIL__STEP_MOCKS, postSlackMessageOnSuccess: mocks.PLATFORM_DEPLOY__POST_SLACK_SUCCESS__STEP_MOCKS, postGithubComment: mocks.PLATFORM_DEPLOY__POST_GITHUB_COMMENT__STEP_MOCKS, @@ -126,7 +125,6 @@ describe('test workflow platformDeploy', () => { assertions.assertDesktopJobExecuted(result, true, false); assertions.assertIOSJobExecuted(result, true, false, true); assertions.assertWebJobExecuted(result, true, false); - assertions.assertHybridAppJobExecuted(result, true); assertions.assertPostSlackOnFailureJobExecuted(result, false); assertions.assertPostSlackOnSuccessJobExecuted(result, true, false); assertions.assertPostGithubCommentJobExecuted(result, true, false); @@ -187,7 +185,6 @@ describe('test workflow platformDeploy', () => { desktop: mocks.PLATFORM_DEPLOY__DESKTOP__STEP_MOCKS, iOS: mocks.PLATFORM_DEPLOY__IOS__STEP_MOCKS, web: mocks.PLATFORM_DEPLOY__WEB__STEP_MOCKS, - hybridApp: mocks.PLATFORM_DEPLOY__HYBRID_APP__STEP_MOCKS, postSlackMessageOnFailure: mocks.PLATFORM_DEPLOY__POST_SLACK_FAIL__STEP_MOCKS, postSlackMessageOnSuccess: mocks.PLATFORM_DEPLOY__POST_SLACK_SUCCESS__STEP_MOCKS, postGithubComment: mocks.PLATFORM_DEPLOY__POST_GITHUB_COMMENT__STEP_MOCKS, @@ -212,7 +209,6 @@ describe('test workflow platformDeploy', () => { assertions.assertDesktopJobExecuted(result, true, false); assertions.assertIOSJobExecuted(result, true, false, true); assertions.assertWebJobExecuted(result, true, false); - assertions.assertHybridAppJobExecuted(result, true); assertions.assertPostSlackOnFailureJobExecuted(result, false); assertions.assertPostSlackOnSuccessJobExecuted(result, true, false); assertions.assertPostGithubCommentJobExecuted(result, true, false); @@ -273,7 +269,6 @@ describe('test workflow platformDeploy', () => { desktop: mocks.PLATFORM_DEPLOY__DESKTOP__STEP_MOCKS, iOS: mocks.PLATFORM_DEPLOY__IOS__STEP_MOCKS, web: mocks.PLATFORM_DEPLOY__WEB__STEP_MOCKS, - hybridApp: mocks.PLATFORM_DEPLOY__HYBRID_APP__STEP_MOCKS, postSlackMessageOnFailure: mocks.PLATFORM_DEPLOY__POST_SLACK_FAIL__STEP_MOCKS, postSlackMessageOnSuccess: mocks.PLATFORM_DEPLOY__POST_SLACK_SUCCESS__STEP_MOCKS, postGithubComment: mocks.PLATFORM_DEPLOY__POST_GITHUB_COMMENT__STEP_MOCKS, @@ -298,7 +293,6 @@ describe('test workflow platformDeploy', () => { assertions.assertDesktopJobExecuted(result, false); assertions.assertIOSJobExecuted(result, false); assertions.assertWebJobExecuted(result, false); - assertions.assertHybridAppJobExecuted(result, false); assertions.assertPostSlackOnFailureJobExecuted(result, false); assertions.assertPostSlackOnSuccessJobExecuted(result, false); assertions.assertPostGithubCommentJobExecuted(result, true, false, false);