Skip to content

Commit

Permalink
fix: Added login for better flow (#38569)
Browse files Browse the repository at this point in the history
## Description
Fix for flaky behaviour.


Fixes #
https://app.zenhub.com/workspaces/stability-pod-6690c4814e31602e25cab7fd/issues/gh/appsmithorg/appsmith/38568


## Automation

/ok-to-test tags="@tag.Settings"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/12705899394>
> Commit: e193fb3
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=12705899394&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.Settings`
> Spec:
> <hr>Fri, 10 Jan 2025 08:50:44 UTC
<!-- end of auto-generated comment: Cypress test results  -->


## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [x] No


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **Tests**
- Updated the existing test case to verify accessibility of all admin
setting sections.
- Enhanced reliability by ensuring a fresh user session before testing
admin settings.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
  • Loading branch information
sagar-qa007 authored Jan 10, 2025
1 parent e12f1bc commit 1030275
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import adminsSettings from "../../../../locators/AdminsSettings";
import {
agHelper,
adminSettings as adminSettingsHelper,
homePage,
} from "../../../../support/Objects/ObjectsCore";

const {
Expand Down Expand Up @@ -210,7 +211,9 @@ describe("Admin settings page", { tags: ["@tag.Settings"] }, function () {
"11. Verify all admin setting sections are accessible",
{ tags: ["@tag.excludeForAirgap"] },
() => {
cy.visit("/applications", { timeout: 60000 });
homePage.LogOutviaAPI();
cy.LoginFromAPI(Cypress.env("USERNAME"), Cypress.env("PASSWORD"));
agHelper.VisitNAssert("/applications", "getAllWorkspaces");
agHelper.GetNClick(adminSettingsHelper._adminSettingsBtn);
cy.wait("@getEnvVariables");
agHelper.GetNClick(adminsSettings.generalTab);
Expand Down

0 comments on commit 1030275

Please sign in to comment.