PromucFlow_constructor/app/client/cypress/e2e/Regression/ClientSide/BugTests
Rahul Barwal ce930598a1
feat: Refactor SelectWidget sourceData handling (#34619)
## Description
This pull request refactors the sourceData handling in the SelectWidget
component. It introduces a dynamic property path for the sourceData in
the SelectWidget configuration, allowing it to be passed as a JSON
string.

This change ensures that the source data matches the sample data passed
for the widget configuration, enabling the switching back of the JS
toggle button.

Additionally, it fixes cypress tests: opening of the prop pane in JS
mode.


Fixes #34568
_or_  
Fixes `Issue URL`
> [!WARNING]  
> _If no issue exists, please create an issue first, and check with the
maintainers if the issue is valid._

## Automation

/ok-to-test tags="@tag.Widget, @tag.Select, @tag.Binding"

### 🔍 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/9758347627>
> Commit: 01e5b4fba240667eaa0818330047489d94c01a46
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=9758347627&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.Widget, @tag.Select, @tag.Binding`
<!-- 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

- **Bug Fixes**
- Improved stability of test scenarios by ensuring JavaScript mode is
toggled appropriately.

- **Tests**
- Updated test cases to include JavaScript mode toggling for more
accurate test outcomes.
- Renamed and restructured test files to enhance clarity and
maintainability.

- **New Features**
- Enhanced `SelectWidget` to initialize `sourceData` with a stringified
array and made `sourceData` dynamically configurable.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-07-03 13:31:35 +05:30
..
AbortAction_Spec.ts chore: unified way of writing messages in cypress (#33659) 2024-05-27 15:34:45 +02:00
AllWidgets_Reset_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
ApiBug6732_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
ApiBugs_Spec.ts chore: unified way of writing messages in cypress (#33659) 2024-05-27 15:34:45 +02:00
Binding_Bug28287_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
Binding_Bug28731_Spec.ts feat: Refactor SelectWidget sourceData handling (#34619) 2024-07-03 13:31:35 +05:30
Bug14987_spec.js test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
Bug20275_Spec.js test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
Bug22281_WelcomeTour_spec.ts feat: removed welcome tour (#30294) 2024-01-17 10:38:29 +05:30
Bug29566_Spec.ts fix: defer data update for js objects (#29564) 2023-12-14 14:10:32 +05:30
Bug30219_Spect.ts fix: schema plus button for a table is visible after template menu is opened (#30849) 2024-02-02 15:26:26 +05:30
CatchBlock_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
DatasourceSchema_spec.ts chore: Show schema as a tab instead of the right pane (#30906) 2024-02-08 13:25:23 +05:30
defaultFilterTextValue_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
DS_Bug18035_Spec.ts test: Cypress - added @tag.excludeForAirgap, @tag.Templates tags (#29790) 2023-12-27 16:50:36 +05:30
DS_Bug19893_spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
DS_Bug21734_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
DS_Bug25148_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
DS_Bug25982_Spec.ts fix: commands title changed to command for each datasource query editor forms (#32526) 2024-04-10 17:05:01 +05:30
DS_Bug26126_spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
DS_Bug26716_Spec.ts test: Cypress - added @tag.excludeForAirgap, @tag.Templates tags (#29790) 2023-12-27 16:50:36 +05:30
DS_Bug26941_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
DS_Bug27817_Spec.ts fix: removed ab_mock_mongo_schema_enabled, ab_gsheet_schema_enabled flag code (#30113) 2024-01-16 14:00:51 +05:30
DS_Bug28750_Spec.ts fix: removed ab_mock_mongo_schema_enabled, ab_gsheet_schema_enabled flag code (#30113) 2024-01-16 14:00:51 +05:30
DS_Bug28985_spec.ts feat: enabled editor pane sidebar (#29882) 2024-01-12 20:13:58 +05:30
DS_Bugs26410_spec.ts fix: commands title changed to command for each datasource query editor forms (#32526) 2024-04-10 17:05:01 +05:30
DSDiscardBugs_spec.ts fix: default port numbers for the datasources (#32901) 2024-04-30 13:15:11 +05:30
formHasChanged_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
GitBugs_Spec.ts fix: missing methods in gitexecutorceimpl (#32614) 2024-04-12 06:21:01 +05:30
GraphQL_Binding_Bug16702_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
ImportExport_Bug24486_Spec.ts feat: enabled editor pane sidebar (#29882) 2024-01-12 20:13:58 +05:30
InputTruncateCheck_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
invalidLintError_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
InvalidURL_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
JS_Bug14002_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
JS_Bug15056_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
JS_Bug15909_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
JS_Bug18369_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
JS_Bug19982_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
JS_Bug20841_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
JS_Bug24194_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
JS_Bug25894_spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
JS_Bug28764_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
JS_Bug29131_spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
JSParse_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30
Moment_Spec.ts fix: removed success toast message for onload js functions (#32700) 2024-04-18 18:19:33 +05:30
SelectWidget_Bug9334_Spec.ts fix: table version changed for crud (#29457) 2023-12-29 17:49:20 +05:30
SortedSchema_Spec.ts fix: sorting schema options alphabetically (#29460) 2023-12-13 13:21:23 +05:30
Widget_Bug27119_Spec.ts test: Cypress - added tags - @tag.Git, @tag.JS, @tag.Binding, @tag.Datasource, @tag.ImportExport (#29516) 2023-12-15 18:28:26 +05:30