PromucFlow_constructor/app/client/cypress/e2e/Regression/ServerSide/OnLoadTests
sneha122 7585a39325
fix: import issue with workspace id fixed (#27653)
## Description

In a case where we are inside an application, then we come back to home
page and add a new workspace and try importing application in that newly
created workspace, the workspace Id that is being sent along with test
API is workspaceId of previous workspace and not the new one. This PR
fixes that issue.

Issue occurs because for test API we are sending workspaceId which we
get from redux state. Whenever we enter inside any application, we set
the currentWorkspace object inside state, this object contains data
about current workspace, but when we leave the application and come back
to home page, we are not resetting this currentWorkspace object, it
still contains stale data, hence when we create new workspace and import
application, it gets workspace id from this stale object.

#### PR fixes following issue(s)
Fixes #27594 
> if no issue exists, please create an issue and ask the maintainers
about this first
>
>
#### Media
> A video or a GIF is preferred. when using Loom, don’t embed because it
looks like it’s a GIF. instead, just link to the video
>
>
#### 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
- [x] Manual
- [ ] JUnit
- [ ] Jest
- [ ] Cypress
>
>
#### Test Plan
1. Login to appsmith, create a new app in a new workspace. Now come back
to home page, and create a new workspace and then import an application.
The reported error should no longer appear
2. Tried with new workspace, new app created and app level import. Here
also the error does not appear.
3. Tried forking an app into a new workspace. Here also error does not
occur
>
>
#### 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
- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [x] 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
- [x] 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
- [x] 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

---------

Co-authored-by: “sneha122” <“sneha@appsmith.com”>
Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2023-09-29 23:55:48 +05:30
..
APIOnLoad_Spec.ts test: Cypress | Simplifying AddDsl method (#24991) 2023-07-04 22:03:31 +05:30
ExecuteAction_Spec.ts test: Cypress | CI Stabilize (#26186) 2023-08-10 12:36:03 +05:30
JSOnLoad_cyclic_dependency_errors_spec.js test: Cypress | Simplifying AddDsl method (#24991) 2023-07-04 22:03:31 +05:30
JSOnLoad1_Spec.ts test: Cypress | CI Stabilize (#26934) 2023-09-04 19:00:21 +05:30
JSOnLoad2_Spec.ts fix: import issue with workspace id fixed (#27653) 2023-09-29 23:55:48 +05:30
JsOnLoad3_Spec.ts test: Cypess | Oracle DS validations added (Part 5) + CI Stabilize (#27440) 2023-09-20 00:56:11 +05:30
OnLoadActions_Spec.ts test: Cypress | Simplifying AddDsl method (#24991) 2023-07-04 22:03:31 +05:30
PostgresConnections_spec.ts feat: enable generate CRUD page for MsSQL plugin (#27195) 2023-09-20 14:12:11 +05:30