Commit Graph

49 Commits

Author SHA1 Message Date
Pawan Kumar
e01b34ec5d
chore: tests for wds button widget (#34242)
/ok-to-test tags="@tag.Anvil"

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

- **New Features**
- Introduced test cases for Anvil Button Widgets, including Canvas,
Preview, and Deploy modes.

- **Bug Fixes**
- Updated CSS and HTML selectors for better element targeting and
testing reliability.

- **Style**
  - Improved styling logic for buttons in the InlineButtons component.

- **Chores**
  - Added `data-testid` attributes for better test targeting.
- Refactored code for string concatenations and URL constructions in
DeployModeHelper.
<!-- end of auto-generated comment: release notes by coderabbit.ai
--><!-- This is an auto-generated comment: Cypress test results -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/9597157402>
> Commit: c551705fe01aace94962fcc7fa91dff253136721
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=9597157402&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.Anvil`

<!-- end of auto-generated comment: Cypress test results  -->

---------

Co-authored-by: Pawan Kumar <pawankumar@Pawans-MacBook-Pro-2.local>
2024-06-20 18:30:16 +05:30
Aishwarya-U-R
30300bb6a4
test: Cypress | Replacing some external api's with TED + Flaky fix (#31118)
## Description
- This PR does some clean up of comments - in DeployHelper.ts
- This PR replaced external image api with TED mock api in
ServerSide/OnLoadTests/OnLoadActions_Spec.ts
- Extrenal example api to TED in Widgets/Image/Image_spec.js
- Extrenal api links in
app/client/cypress/e2e/Regression/ServerSide/ApiTests/API_Bugs_Spec.js
to TED api's
- Flaky fixes /ServerSide/LoginTests/LoginFailure_spec.js - for EE CI
run failure (Added multiple Dynamic checks)
- support command.js method LoginUser() - added Dynamic check
- Encapsulated Datasources/Arango_Basic_Spec.ts into conditional check
to run in CE alone, instead of entirely skipping, since its failing in
EE due to chrome crash

#### Media
#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing
#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed

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

- **Tests**
- Updated Cypress regression tests to use flower images instead of cat
images for API calls.
- Modified limited test configurations to run with different spec files.
- Adjusted GitHub Actions workflow to change `matrix_count` values based
on the event type and retrieve PR number for manual triggers.
	- Updated Docker image tag in CI tests to `nightly`.

- **Refactor**
- Enhanced `DataManager` class with new properties for flower image
URLs.
- Improved `EntityExplorer` class method to ensure more reliable
triggering of events.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-02-23 13:18:01 +05:30
Aishwarya-U-R
515e28a6f1
test: Cypress | Added Dynamic checks for Flaky fix + Cypress upgrade (#30840)
## Description
- This PR does below:
-
cypress/e2e/Regression/ClientSide/Templates/Fork_Template_To_App_spec.js
(to .ts with flaky fix)
- cypress/e2e/Sanity/Datasources/SMTPDatasource_spec.js (multiple runs,
no fix was needed, removed from skipped list)
- Cypress upgrade from 13.6.1 to 13.6.4
- cypress/e2e/Regression/ClientSide/EmbedSettings/EmbedSettings_spec.js
(flaky fix)
- cypress/e2e/Regression/ServerSide/QueryPane/S3_1_spec.js (6th test -
flaky fix)
- assertHelper.WaitForNetworkCall() - reduced wait timeout
- deployHelper.DeployApp() added dynamic checks
- cypress/e2e/Regression/ClientSide/Git/GitSync/SwitchBranches_spec.js
(removed redundant before hook to fix flakyness)
- cypress/e2e/Regression/ClientSide/Git/GitImport/GitImport_spec.js
(removed redundant before hook to fix flakyness)

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing

#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed

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

- **New Features**
- Introduced functionality for forking a template to the current app and
adding selected pages from a template.
- **Bug Fixes**
- Enhanced test stability by replacing sleep calls with dynamic wait
conditions.
- Improved test reliability and performance by adjusting waiting
conditions for network calls and element assertions.
- **Tests**
- Updated the list of Cypress tests to include new scenarios and remove
outdated ones.
- Added new end-to-end tests for template forking and embed settings
validation.
- **Chores**
- Optimized test support files and functions for better code maintenance
and readability.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-02-02 16:01:59 +05:30
Vemparala Surya Vamsi
ad68825818
feat: Frontend changes for consolidated-api with EE test case support (#30506) 2024-01-24 12:14:16 +05:30
Vemparala Surya Vamsi
8bb61d996a
chore: reverted consolidated api (#30314)
## Description
Reverted consolidated api changes and also some CE related changes to
make it compatible with EE.
#### PR fixes following issue(s)
Reverts  #29650 & #29939

#### Type of change

- Chore (housekeeping or task changes that don't impact user perception)
>
>
>
## Testing
#### How Has This Been Tested?
- [ ] Manual
- [ ] JUnit
- [ ] Jest
- [x ] 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 is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **Refactor**
- Enhanced the reliability and efficiency of Cypress e2e tests by
adjusting wait conditions and assertions.
	- Simplified network request handling across various test cases.
- Updated test logic to align with changes in application data structure
and network requests.

- **Tests**
- Improved test stability for application import/export, Git sync, page
load behavior, and widget interactions.
- Refined mobile responsiveness tests to accurately validate layout
conversions and autofill behaviors.

- **Chores**
- Removed deprecated feature flags and code related to consolidated page
load functionality.
- Cleaned up unused parameters and simplified action payloads in Redux
actions.

- **Documentation**
	- Updated comments for clarity in test specifications.

- **Style**
	- Adjusted code styling for consistency across test suites.

- **Bug Fixes**
- Fixed data retrieval logic in tests to ensure correct data extraction
from API responses.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-01-16 10:16:48 +05:30
Vemparala Surya Vamsi
96701c343d
feat: Frontend changes for consolidated-api (#29933)
## Description
Our objective in this pr is to improve the page load time of our
application by calling a consolidated-api which contains all the
resources to load our pages. This PR contains all the client side
changes to call the consolidated-api as well as feature flag related
changes.
Fixes #29650 & #29939
#### Type of change
- Chore (housekeeping or task changes that don't impact user perception)
## Testing
>
#### How Has This Been Tested?
- [x] Manual
- [ ] JUnit
- [ ] Jest
- [x] 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
- [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
- [x] New and existing unit tests pass locally with my changes
- [x] 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 is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **Refactor**
- Updated network request aliases and response handling in end-to-end
tests.
- **New Features**
- Introduced a new API class `ConsolidatedPageLoadApi` for fetching
consolidated page load data.
- **Tests**
	- Enhanced testing for application URL navigation and data retrieval.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-01-15 10:00:29 +05:30
Aishwarya-U-R
5b0ffb84a9
test: Cypress | CI Stabilize (#28403)
## Description
- agHelper.SimulateCopyPaste() added
- Added 'Cannot read properties of undefined' error toast absence check
- Adding matchCase:false into GetNClickByContains() for
CommunityIssues.spec flaky

**Flaky fixes below:**
- OtherUIFeatures/ApplicationURL_spec.js flaky fix
-
cypress/e2e/Regression/ClientSide/Git/ExistingApps/v1.9.24/DSCrudAndBindings_Spec.ts
- Git/GitImport/GitImport_spec.js
- ClientSide/DynamicHeight/List_TextWidget_Spec.ts
- ServerSide/QueryPane/S3_2_spec.ts
- Others/IconButton_2_spec.ts

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing

#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed
2023-10-27 18:43:28 +05:30
Ayush Pahwa
d80fa0aeee
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
2023-10-25 21:29:28 +05:30
Aishwarya-U-R
e9a1f86e22
test: Cypress | CI Stablize + Other improvements (#28254)
## Description
**This PR does the below improvements:**
- Handles initial empty error toast- with cy.LogOut()
- Calling cy.LoginFromAPI() per need only - to improve execution time 
- Update agHelper.UpdateCodeInput()
- Added waitForNetworkCall for AsserHelper methods to only get api call
& validate
- Added gitSync.AuthorizeKeyToGitea() - to validate keyGenerate success
- Adding validationg for 'Unable to import application in workspace'
- cy.CreateNewAppInNewWorkspace() improved
- agHelper.RemoveUIElement() created to handle tooltip, toast,
evaluatedpopup & removed duplicates
- cy.merge() improved to call assertHelper
- assertHelper.AssertNetworkStatus() to handle both array & individual
status checks & return actual responseCode
- createBranch & generatedKey intercepts added to git operation
validations
- homePage.AssertApplication() created
- Removed cy.Logout() & Login improved - brings down total run time to
less than 1 hr from 1+ hrs
- entityExplorer.NavigateToSwitcher() improved to check status
- dataSources.ValidateDSDeletion() improved to handle one of array toast
for array value also
- assertHelper.WaitForNetworkCall() improved to wait & return latest
request
- Private methods processNetworkStatus() & processNetworkResponseData()
created
  
**Also flaky fixes below:**
- ServerSide/QueryPane/S3_2_spec.ts - Adding sleep for CI flaky
behaviour
- Trial fix for
cypress/e2e/Regression/ClientSide/OtherUIFeatures/PageOnLoad_spec.ts
- GitWithJSLibrary/GitwithCustomJSLibrary_spec.js - Handling Import
failure at various points in the flow
- ExplorerTests/Widgets_Copy_Paste_Delete_Undo_Keyboard_Event_spec.js
   - ClientSide/JSLibrary/Library_spec.ts - asserting success import
   - /OtherUIFeatures/ApplicationURL_spec.js - using cy.url()
   - /ClientSide/Templates/Fork_Template_spec.js
- ServerSide/Postgres_DataTypes/Binary_Spec.ts &
/Postgres_DataTypes/Json_Spec.ts - Adding sleep for CI flaky behaviour
   - ClientSide/Widgets/List/List4_2_spec.js
   - /Git/ExistingApps/v1.9.24/DSCrudAndBindings_Spec.ts

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing

#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed
2023-10-25 19:33:07 +05:30
Aishwarya-U-R
4ffc5bb62a
test: Cypress | CI Stabilize + Other test improvements (#28172)
## Description
- **This PR flaky fixes below specs:**
    - GenerateCRUD/MySQL2_Spec.ts script fix
   - ServerSide/ApiTests/API_All_Verb_spec.js
   - Regression/Apps/PromisesApp_spec.js
   - TableV2_Property_ToggleJs_With_Binding_spec.js
   - GSheet cases failures due to EditApponHover method fix
- Radio/Radio2_spec.ts, using `GetHeight` instead of
`GetWidgetCSSHeight`
   - Select/Select3_Spec.ts
   - Widgets/Text/Text_new_feature_spec.js
   - Binding/API_with_List_Widget_spec.js
   - Workspace/LoginFromUIApp_spec.js - removed redundant code
   - QueryPane/DSDocs_Spec.ts
   - ServerSide/QueryPane/GoogleSheets_spec.ts
   - TableV2/Date_column_editing_1_spec.ts
- Git/ExistingApps/v1.9.24/DSCrudAndBindings_Spec.ts - script flow
corrected
   - ServerSide/QueryPane/Mongo_Spec.js
- **Added validation for form plugin response data, which addresses the
Empty toast issue**

- **Below specs are fixed for new appName localStorage changes:**
    - /SettingsPane/PageSettings_spec.ts
    - BugTests/Moment_Spec.ts
    - /Fork/ForkAppWithMultipleDS_Spec.ts
    - Fork/ForkApplicationWithinAppEditor_spec.ts
    - Fork/ForkApplication_spec.ts
    - /ClientSide/OtherUIFeatures/Analytics_spec.js
    - OtherUIFeatures/ApplicationURL_spec.js
    - OtherUIFeatures/ExportApplication_spec.js - Duplicate case removed
    - OtherUIFeatures/UpdateApplication_spec.js
    - VisualTests/JSEditorIndent_spec.js
    - Workspace/WorkspaceImportApplication_spec.js
 
- **Improvemnets:**
- deployMode.StubWindowNAssert() improved to validate `getPluginForm`
instead of `getWorkspace`
  - agHelper.AddDsl() improved, removed wait times
  - appSettings.CheckUrl() - appName url updated
  - assertHelper.AssertDocumentReady() -removed wait times
- assertHelper.AssertNetworkResponseData() - added for `getPluginForm`
validation for Page loads
  - deployMode.DeployApp() -removed wait times
- homePage.CreateNewWorkspace() - improved to set localStorage for
workspaceName, workspaceId & create new workspace without new name
- homePage.CreateNewApplication() - - improved to set localStorage for
appName
  - jsEditor.NavigateToNewJSEditor() - improved to remove tooltip
- cy.CreateAppInFirstListedWorkspace() - improved to set localStorage
for appName, removed waitTimes, Removed rename of every app for every
spec, calling AssertNetworkResponseData(getPluginForm)
  - cy.DeleteWorkspaceByApi() added
- e2e.js - removed guid generation for first app, added
cy.DeleteWorkspaceByApi() in after()
  
#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing

#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed
2023-10-20 07:45:47 +05:30
Aishwarya-U-R
61db723d35
test: Cypress | Firestore validations added + CI Stabilize (#27554)
## Description
- This PR adds below validation for firestore DS
- Firestore - Added documentation verification (added Staging dummy data
for Firestore DS)
  - Firestore - Added mandatory fields validations
  - Firestore - added placeholder validation
  - Firestore - Added widget binding & deploy app validation
  - Firestore - DS logo validation
- Flaky fix - Templates/Filtering/TemplatesModal_filtering_spec.ts
- CreateAppInFirstListedWorkspace() improved to navigate to New
Application edit page after creation
- Pin_Spec.js - updated validation for airgap
- Trial fix - ServerSide/Datasources/Oracle_Spec.ts
- Removing cypress/package.json as its not used

#### Type of change
- Script update (non-breaking change which fixes an issue)

## Testing
>
#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed

---------

Co-authored-by: Parthvi <80334441+Parthvi12@users.noreply.github.com>
2023-09-25 20:02:54 +05:30
Aishwarya-U-R
0c8ed66d86
test: Cypress | CI Stabilize (#27493)
## Description
- This PR fixes the flaky /ClientSide/OtherUIFeatures/Omnibar_spec.js
- Removed added parameter from CreateDataSource()
- Fixed MsSQL to use same DS thruout
- Fix on StubWindowNAssert() to check the external link navigation
related issues
- using TS Refresh() in Onboarding.skipSignposting() + Added timeout for
#sidebar visibility to check app load empty toast issue
- Trial fix
cypress/e2e/Regression/ClientSide/Binding/Button_Text_WithRecaptcha_spec.js

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing
#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed
2023-09-21 00:41:08 +05:30
Aishwarya-U-R
a8c50cfb37
test: Cypess | Oracle DS validations added (Part 5) + CI Stabilize (#27440)
## Description
- This PR adds below:
- Oracle - Delete table data validation
- Deploy App & verify the deleted data
- Bind query to already existing table widget, deploy, Filter table &
verify
- Improved AssertPopoverTooltip - to handle both tooltip elements
- Oracle - Copy, Move query validated [Tc #
2363](https://github.com/appsmithorg/TestSmith/issues/2363)
- Oracle - Query settings page validation covered [Tc #
2365](https://github.com/appsmithorg/TestSmith/issues/2365)
- Oracle - Widgets (Select, DatePicker) to Insert query binding [Tc #
2366](https://github.com/appsmithorg/TestSmith/issues/2366)
- Updated ToggleConfirmBeforeRunning() to run for Api & Queries
- Enabling limited-workflow re-run

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing
>
#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed
2023-09-20 00:56:11 +05:30
Aishwarya-U-R
178f8f16f5
test: Cypress | (DI) S3 added validations (Cont.,) + CI Stabilize (#26486)
## Description
**- This PR includes below:**
- NavigateBacktoEditor() improved
- Flaky fixed - ClientSide/EmbedSettings/EmbedSettings_spec.js- 1st test
- ServerSide/QueryPane/S3_1_spec.js - 1st test - handling added error
message
- Sanity/Datasources/Arango_Basic_Spec.ts - 3rd test - schema pop-up
handle
- ClientSide/FormLogin/EnableFormLogin_spec.js - server restart fix
- Moved AssertNetworkExecutionSuccess to AssertHelper
- GetNAssertContains() simplified
- Widgets/ListV2/DataIdentifierProperty_spec.ts - 7th case flaky fix
- /Widgets/Checkbox/CheckboxGroup2_spec.js - flaky fix
- BugTests/AllWidgets_Reset_Spec.ts - script improved
- /Widgets/Radio/Radio_spec.js - script improved
- AssertExistingCheckedState() improved to validate attribute & checked
state
- ClickButton() improved
- AssertElementEnabledDisabled() improved
- UpdateInput(), replaced with TypeText()
**- New scripting for:**
- S3 - Deploy mode validations added
- S3 - Edit File validation added from Deploy page
- S3 - Upon file upload, validating button changes
- S3 - Verify max number of files upload
- S3 - File name Prefix search & Delete improved
- S3_2_spec from js to ts helpers
- Tc # 2439 scripted

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing
>
#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed
2023-08-21 13:19:28 +05:30
Aishwarya-U-R
a0db49d1f4
test: Cypress | (DI) Arango added validations + CI Stabilize (#26243)
## Description
- This PR does the below:
- EnterJsContext to use ToggleJSMode
- Adding limited-tests.txt to gitignore
- Added S3, Arango Documentation verify
- Added Arango Widget binding + validation to Insert data
- Upgraded Cypress from 12.17.2 to 12.17.4
- Update Arango spec to read DS values from TestConfig.ts file instead
of dataSources.json
- Arango Suggested widget + Schema search
- Flaky fix - Regression/ServerSide/QueryPane/DSDocs_Spec.ts
- Flaky fix - GenerateCRUD/Postgres1_Spec.ts - improving
NavigateBacktoEditor() method to tackle all Deploy to Edit mode
navigations (to monitor)
- Viewport updated for sharper screenshots/videos
- Improve waitForServerRestart js support method (+ server restart
timeout increased)
- Fix Binding/API_with_List_Widget_spec.js - 3rd case
- Widgets/WidgetPropertySetters_spec.ts - updated
- Flaky fix - ServerSide/QueryPane/S3_1_spec.js - 1st case
- Binding/Promises_1_Spec.ts
- ClientSide/BugTests/ApiBugs_Spec.ts
- Update TedTestConfig to DataManager since out of TED datasources are
also present in this file like Arango, Elastic Mssql etc
- Improved AssertPropertiesDropDownCurrentValue()

#### Type of change
- Script fix & New scripts (non-breaking change which fixes an issue)
## Testing
>
#### How Has This Been Tested?
- [X] Cypress CI runs
>
>

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after changes are reviewed
2023-08-18 10:48:35 +05:30
Aishwarya-U-R
a85fc7f5de
test: Cypress | CI Stabilize (#26186)
## Description
- Regression/ServerSide/LoginTests/LoginFailure_spec.js
- Workspace/ShareAppTests_Spec.ts
- Api EnterURL method improved
- agHelper.AssertElementVisibility() improved
- Git/ExistingApps/v1.9.24/DSCrudAndBindings_Spec.ts
- Apps/PgAdmin_spec.js - increased wait time
- productAlert intercept improved

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing
>
#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after changes were reviewed
2023-08-10 12:36:03 +05:30
Aishwarya-U-R
af415f4f30
test: Cypress | Automated tests for MySQL + Flaky fixes (#25867)
## Description
- This PR fixes the below flaky fixes
- GitSyncedApps_spec.js
- Improves coverage for MySQl - adding suggested widget binding
- TableV2/Date_column_editing_1_spec.ts fix
- WaitUntilEleAppear improved
- DeployApp() updated
- QueryPane/Mongo_Spec.js - adding wait time
- AssertIfPropertyIsNotVisible() replaced
- fat-migration.yml deleted
- cypress-real-events - update
- /Filepicker/FilePicker2_spec.js
- /Autocomplete/Autocomplete_setters_spec.ts

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing
>
#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed
2023-08-01 15:04:15 +05:30
Aishwarya-U-R
e6ee5e7348
test: Cypress | Automated cases for MongoURI CRUD (#25837)
## Description
- This PR is adding new scripts for Mongo URI CRUD validations
- Add/Update/Delete from CRud page
- Search table
- FIlter table
- Download results
- Suggested widget from a mongo uri query
- Apps/CommunityIssues_Spec.ts - 5th fix

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing
>
#### How Has This Been Tested?
- [X] Cypress
- 
## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed
2023-07-31 16:57:07 +05:30
Ayush Pahwa
eb83389b3c
fix: multiple env issues (#25655)
## Description
Fixes for issues found during ME regression

#### PR fixes following issue(s)
Fixes #25640 
Fixes #25653
2023-07-25 15:34:37 +07:00
ChandanBalajiBP
5024a52ccd
chore: Update cypress locators for ME (#25603)
> Pull Request Template
>
> Use this template to quickly create a well written pull request.
Delete all quotes before creating the pull request.
>
## Description
> Add a TL;DR when description is extra long (helps content team)
>
> Please include a summary of the changes and which issue has been
fixed. Please also include relevant motivation
> and context. List any dependencies that are required for this change
>
> Links to Notion, Figma or any other documents that might be relevant
to the PR
>
>
#### PR fixes following issue(s)
Fixes # (issue number)
> 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
> Please delete options that are not relevant.
- Bug fix (non-breaking change which fixes an issue)
- New feature (non-breaking change which adds functionality)
- Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- Chore (housekeeping or task changes that don't impact user perception)
- This change requires a documentation update
>
>
>
## 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
- [ ] 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
2023-07-22 10:18:35 +07:00
Ayush Pahwa
75b297201a
chore: code splitting for multiple env feature (#25479)
code split for EE feature

---------

Co-authored-by: ChandanBalajiBP <104058110+ChandanBalajiBP@users.noreply.github.com>
Co-authored-by: Parthvi <80334441+Parthvi12@users.noreply.github.com>
2023-07-21 12:53:17 +07:00
Vijetha-Kaja
d7202abbc8
test: Cypress - Gitea App Automation (#25144)
## Description

**Fixed below flaky tests**

- Gitea app automation , validations covered:
    - A successful api call
    - An unsuccessful api cal
    - CRUD pages for DS - Postgres, Mongo, Mysql
    - CRUD table validations in Deploy page
    - Widgets & their bindings validations
    - Update JSObjects, bind it to widget & Validate updated response

## Type of change

- New feature

## How Has This Been Tested?
- Cypress test runs

## Checklist:
### QA activity:
- [ ] Test plan has been approved by relevant developers
- [ ] Test plan has been peer reviewed by QA
- [ ] Cypress test cases have been added and approved by either SDET or
manual QA
- [ ] Organized project review call with relevant stakeholders after
Round 1/2 of QA
- [ ] Added Test Plan Approved label after reveiwing all Cypress test

---------

Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2023-07-11 22:09:13 +05:30
Aishwarya-U-R
8e868b3093
test: Cypress | Flaky fixes (#25087)
## Description
- This PR improves RefreshPage()
- Improves StubbingDeployPage()
- Fixes below flaky tests;
- Datasources/ElasticSearch_Basic_Spec.ts
- Datasources/MsSQL_Basic_Spec.ts

#### Type of change
- Script fix (non-breaking change which fixes an issue)
## Testing
>
#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [ ] Added `Test Plan Approved` label after changes were reviewed
2023-07-06 10:43:15 +05:30
Aishwarya-U-R
22dce834d1
test: Cypress | Flakyfix + New Scripts (#25085)
## Description
- This PR has below:
- improves StubWindowNAssert()
- Adds new test for Bug # 25004
- AssertNetworkStatus() fixed

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing
>
#### How Has This Been Tested?
- [X] Cypress local runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after changes were reviewed
2023-07-05 02:08:31 +05:30
Aishwarya-U-R
63eae07346
test: Cypress | Flaky fixes (#24925)
## Description
This PR upgrades Cypress from 12.14 to Cy 12.16 along with below flaky
fixes:
- This PR fixes the below flakyness in Cypress suite:
- ConversionAlgorithm_AutoLayout_Valid.js
- ButtonGroup_MenuButton_Width_spec.js
- columntypes/select_spec - method update
- Date_column_editing_1_spec.js
- Omnibar_spec.js - 6th case
- TableV2_Widget_API_Pagination_spec.js
- TableV2_Widget_API_Derived_Column_spec.js
- TableV2TextPagination_spec.js
- Table_Widget_API_Pagination_spec.js
- TableTextPagination_spec.js
- Table_Derived_Column_Data_validation_spec.js
- LoginTests/LoginFailure_spec.js
- cy.visit - timeouts handled
- CreateQueryAfterDSSaved for Mock DB's
- TableV2Filter1_2_Spec
- InputTruncateCheck_Spec
- DSDocs_Spec - for assertNewtab open
- TableV2_DisplayText_spec
- MultiSelect3_spec
- PropertyPaneSuggestion_spec
- Others/Video_spec.js

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing
#### How Has This Been Tested?
- [X] Cypress

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after changes tests were reviewed
2023-07-01 00:16:57 +05:30
Aishwarya-U-R
6df0810cc9
test: Cypress | Flaky fixes (#24723)
## Description
- This PR fixes below flaky specs:
          -   GitDiscardChange/DiscardChanges_spec.js
          - Socket closed before finished writing response fix
          - Workspace/ShareAppTests_spec.js (NavigateBacktoEditor() fix)

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing

#### How Has This Been Tested?
- [X] Cypress

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after changes are reviewed
2023-06-22 17:35:59 +05:30
Ivan Akulov
bc0426dad2
perf: prioritize the main bundle over preloads (v2) (#24374) 2023-06-22 10:58:10 +05:30
Aishwarya-U-R
99f6e2cf29
test: Cypress (#24586)
## Description
- This PR adds the No Error toast to NavigateBacktoEditor() which
sometimes results in Edit page not being load in CI runs
2023-06-18 17:15:26 +05:30
Aishwarya-U-R
084e28ab21
test: Cypress | Flaky fixes (#24581)
## Description
- This PR fixes the below flaky:
- ReconnectDatasource_spec.js
- ConversionAlgorithm_AutoLayout_Validation_BasicSpec.js
- Improves CreateApplication with intercept assert
- Changes all agHelper.AssertN.wStatus to assertHelper() method

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing
>
#### How Has This Been Tested?
- [X] Cypress CI runs

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed
2023-06-18 10:25:16 +05:30
Aishwarya-U-R
959fdce6ac
test: Cypress | Flaky fixes (#24508)
## Description
- This PR improves the sign up method to work even if telemetry related
details are not asked at start
- Also alters the Commit message based on the repository/workflow or
push runs
 - Improves DragDropWidgetNVerify()
 - Fixes flaky TableV2/Inline_editing_spec.js spec with TS methods
 - Improved EditTableCell()
 - Skipping deleting apps during local runs for debugging purpose
 - Fixes PropertyPane_Search_spec.ts
- Fixed ever flaky AppNavigationWithMultiplePages_spec,
AppNavigationWithAutoLayout_spec

#### Type of change
- Script fix (non-breaking change which fixes an issue)

## Testing
>
#### How Has This Been Tested?

- [X] Cypress CI runs
>
>

## Checklist:
#### QA activity:
- [ ] Added `Test Plan Approved` label after changes were reviewed
2023-06-17 00:10:10 +05:30
Aishwarya-U-R
d7b2bad974
test: Cypress | Cy 12 upgrade + Flaky fixes (#23852)
## Description
- This PR upgrades cypress from 11.2 to 12.13.0 which fixes the random
browser crash issue in CI runs
 - ValidateNetworkStatus() updates to validate the n/w responses
 - cy.route() to cy.intercept()
 - Converting dataSources.json to HostPort.ts
 - Api responses read - updating to right Cy12 supported format
- js inconsistent testJsontext to TS `EnterJSContext` in few failing
specs
 - CI - higher resolution trials
- Improves _.agHelper.RefreshPage() - fixing Error: Socket closed before
finished writing response
 - AssertDocumentReady() created
 - within(()) & .children() - handled for Cy12
- Improved DeployApp(), NavigateBacktoEditor(), RefreshPage(), AddDsl()
methods
- js inconsistent goToEditFromPublish to TS `NavigateBacktoEditor` in
all specs
- js inconsistent PublishtheApp to TS `_.agHelper.DeployApp` in all
specs
- Convert /DynamicHeight/Text_Widget_spec.js to TS with all supporting
TS helpers
 - ToggleJSMode()
 - COMMIT_INFO_MESSAGE improved
 - Remove tooltip on the Application Name after rename
- js inconsistent cy.addDsl(dsl); to TS helper `_.agHelper.AddDsl(val);`
 - ++++ Much more improvements....

#### Type of change
- Script fixes

## Testing
#### How Has This Been Tested?
- [X] Cypress

## Checklist:
#### QA activity:
- [X] Added `Test Plan Approved` label after Cypress tests were reviewed

---------

Co-authored-by: Vijetha-Kaja <vijetha@appsmith.com>
2023-06-15 18:51:11 +05:30
Aman Agarwal
e558a2ecc2
feat: disabling the toast messages on view mode without debug flag (#23768)
## Description
When the application is in published mode, this Pr offers the ability to
disable the error toast. Only the toasts that the user initiated are
displayed; all others are disabled and messages are logged in the
console.
When the view mode url has `debug=true` as one of the query params, then
all the error toasts are visible.

#### PR fixes following issue(s)
Fixes #23605
Fixes #23603 

#### 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
> Please delete options that are not relevant.
- Bug fix (non-breaking change which fixes an issue)
- New feature (non-breaking change which adds functionality)
- Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- Chore (housekeeping or task changes that don't impact user perception)
- This change requires a documentation update
>
>
>
## 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
- [ ] 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/Test-plan-implementation#speedbreaker-features-to-consider-for-every-change)
have been covered
- [ ] Test plan covers all impacted features and [areas of
interest](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans/_edit#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
2023-06-09 19:28:45 +05:30
albinAppsmith
629999f124
feat: [epic] appsmith design system version 2 deduplication (#22030)
## Description

### Fixes
- [x] https://github.com/appsmithorg/appsmith/issues/19383
- [x] https://github.com/appsmithorg/appsmith/issues/19384
- [x] https://github.com/appsmithorg/appsmith/issues/19385
- [x] https://github.com/appsmithorg/appsmith/issues/19386
- [x] https://github.com/appsmithorg/appsmith/issues/19387
- [x] https://github.com/appsmithorg/appsmith/issues/19388
- [x] https://github.com/appsmithorg/appsmith/issues/19389
- [x] https://github.com/appsmithorg/appsmith/issues/19390
- [x] https://github.com/appsmithorg/appsmith/issues/19391
- [x] https://github.com/appsmithorg/appsmith/issues/19392
- [x] https://github.com/appsmithorg/appsmith/issues/19393
- [x] https://github.com/appsmithorg/appsmith/issues/19394
- [x] https://github.com/appsmithorg/appsmith/issues/19395
- [x] https://github.com/appsmithorg/appsmith/issues/19396
- [x] https://github.com/appsmithorg/appsmith/issues/19397
- [x] https://github.com/appsmithorg/appsmith/issues/19398
- [x] https://github.com/appsmithorg/appsmith/issues/19399
- [x] https://github.com/appsmithorg/appsmith/issues/19400
- [x] https://github.com/appsmithorg/appsmith/issues/19401
- [x] https://github.com/appsmithorg/appsmith/issues/19402
- [x] https://github.com/appsmithorg/appsmith/issues/19403
- [x] https://github.com/appsmithorg/appsmith/issues/19404
- [x] https://github.com/appsmithorg/appsmith/issues/19405
- [x] https://github.com/appsmithorg/appsmith/issues/19406
- [x] https://github.com/appsmithorg/appsmith/issues/19407
- [x] https://github.com/appsmithorg/appsmith/issues/19408
- [x] https://github.com/appsmithorg/appsmith/issues/19409

Fixes # (issue)
> 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

> Please delete options that are not relevant.

- Bug fix (non-breaking change which fixes an issue)
- New feature (non-breaking change which adds functionality)
- Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- Chore (housekeeping or task changes that don't impact user perception)
- This change requires a documentation update


## How Has This Been Tested?
> Please describe the tests that you ran to verify your changes. Provide
instructions, so we can reproduce.
> Please also list any relevant details for your test configuration.
> Delete anything that is not important

- Manual
- 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:
- [ ] Test plan has been approved by relevant developers
- [ ] Test plan has been peer reviewed by QA
- [ ] Cypress test cases have been added and approved by either SDET or
manual QA
- [ ] Organized project review call with relevant stakeholders after
Round 1/2 of QA
- [ ] Added Test Plan Approved label after reveiwing all Cypress test

---------

Co-authored-by: Ankita Kinger <ankita@appsmith.com>
Co-authored-by: akash-codemonk <67054171+akash-codemonk@users.noreply.github.com>
Co-authored-by: Tanvi Bhakta <tanvi@appsmith.com>
Co-authored-by: Arsalan <arsalanyaldram0211@outlook.com>
Co-authored-by: Aman Agarwal <aman@appsmith.com>
Co-authored-by: Rohit Agarwal <rohit_agarwal@live.in>
Co-authored-by: Nilesh Sarupriya <nilesh@appsmith.com>
Co-authored-by: Nilesh Sarupriya <20905988+nsarupr@users.noreply.github.com>
Co-authored-by: Tanvi Bhakta <tanvibhakta@gmail.com>
Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
Co-authored-by: Parthvi Goswami <parthvigoswami@Parthvis-MacBook-Pro.local>
Co-authored-by: Vijetha-Kaja <vijetha@appsmith.com>
Co-authored-by: Parthvi <80334441+Parthvi12@users.noreply.github.com>
Co-authored-by: Apple <nandan@thinkify.io>
Co-authored-by: Saroj <43822041+sarojsarab@users.noreply.github.com>
Co-authored-by: Sangeeth Sivan <74818788+berzerkeer@users.noreply.github.com>
Co-authored-by: Ashok Kumar M <35134347+marks0351@users.noreply.github.com>
Co-authored-by: Aishwarya-U-R <91450662+Aishwarya-U-R@users.noreply.github.com>
Co-authored-by: rahulramesha <rahul@appsmith.com>
Co-authored-by: Aswath K <aswath.sana@gmail.com>
Co-authored-by: Preet Sidhu <preetsidhu.bits@gmail.com>
Co-authored-by: Vijetha-Kaja <119562824+Vijetha-Kaja@users.noreply.github.com>
Co-authored-by: Shrikant Sharat Kandula <shrikant@appsmith.com>
2023-05-20 00:07:06 +05:30
Dhruvik Neharia
9d5e2e0246
feat: App navigation - Logo upload (#22297)
## Description

Allowing users to upload a logo to show in the navigation along with
toggles to hide logo or application title.

Fixes #20134
Fixes #21946
Fixes #22260

## Media
<video
src="https://user-images.githubusercontent.com/22471214/235613131-129ac2ed-b994-4eab-8eba-7db297c2f7fd.mp4"><video>

## Type of change
- New feature (non-breaking change which adds functionality)

## How Has This Been Tested?
- Manual

### Test Plan
> https://github.com/appsmithorg/TestSmith/issues/2376

### 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
- [x] New and existing unit tests pass locally with my changes
- [ ] PR is being merged under a feature flag


### QA activity:
- [ ] Test plan has been approved by relevant developers
- [ ] Test plan has been peer reviewed by QA
- [ ] Cypress test cases have been added and approved by either SDET or
manual QA
- [ ] Organized project review call with relevant stakeholders after
Round 1/2 of QA
- [ ] Added Test Plan Approved label after reveiwing all Cypress test
2023-05-05 12:19:20 +05:30
Valera Melnikov
96c42d75d4
chore: improve husky and lint-staged checks (#21679)
## Description

1. Update husky, prettier and lint-staged then move them to
devDependencies
2. Configure husky and lint-staged
3. Impriove rules for the lint commands
4.  Fix errors of eslint and prettier. 
5. Remove redundant files

## Type of change


- Chore (housekeeping or task changes that don't impact user perception)


Co-authored-by: Valera Melnikov <melnikov.vv@greendatasoft.ru>
2023-03-23 17:02:18 +05:30
Ivan Akulov
424d2f6965
chore: upgrade to prettier v2 + enforce import types (#21013)Co-authored-by: Satish Gandham <hello@satishgandham.com> Co-authored-by: Satish Gandham <satish.iitg@gmail.com>
## Description

This PR upgrades Prettier to v2 + enforces TypeScript’s [`import
type`](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-8.html#type-only-imports-and-export)
syntax where applicable. It’s submitted as a separate PR so we can merge
it easily.

As a part of this PR, we reformat the codebase heavily:
- add `import type` everywhere where it’s required, and
- re-format the code to account for Prettier 2’s breaking changes:
https://prettier.io/blog/2020/03/21/2.0.0.html#breaking-changes

This PR is submitted against `release` to make sure all new code by team
members will adhere to new formatting standards, and we’ll have fewer
conflicts when merging `bundle-optimizations` into `release`. (I’ll
merge `release` back into `bundle-optimizations` once this PR is
merged.)

### Why is this needed?

This PR is needed because, for the Lodash optimization from
7cbb12af88,
we need to use `import type`. Otherwise, `babel-plugin-lodash` complains
that `LoDashStatic` is not a lodash function.

However, just using `import type` in the current codebase will give you
this:

<img width="962" alt="Screenshot 2023-03-08 at 17 45 59"
src="https://user-images.githubusercontent.com/2953267/223775744-407afa0c-e8b9-44a1-90f9-b879348da57f.png">

That’s because Prettier 1 can’t parse `import type` at all. To parse it,
we need to upgrade to Prettier 2.

### Why enforce `import type`?

Apart from just enabling `import type` support, this PR enforces
specifying `import type` everywhere it’s needed. (Developers will get
immediate TypeScript and ESLint errors when they forget to do so.)

I’m doing this because I believe `import type` improves DX and makes
refactorings easier.

Let’s say you had a few imports like below. Can you tell which of these
imports will increase the bundle size? (Tip: it’s not all of them!)

```ts
// app/client/src/workers/Linting/utils.ts
import { Position } from "codemirror";
import { LintError as JSHintError, LintOptions } from "jshint";
import { get, isEmpty, isNumber, keys, last, set } from "lodash";
```

It’s pretty hard, right?

What about now?

```ts
// app/client/src/workers/Linting/utils.ts
import type { Position } from "codemirror";
import type { LintError as JSHintError, LintOptions } from "jshint";
import { get, isEmpty, isNumber, keys, last, set } from "lodash";
```

Now, it’s clear that only `lodash` will be bundled.

This helps developers to see which imports are problematic, but it
_also_ helps with refactorings. Now, if you want to see where
`codemirror` is bundled, you can just grep for `import \{.*\} from
"codemirror"` – and you won’t get any type-only imports.

This also helps (some) bundlers. Upon transpiling, TypeScript erases
type-only imports completely. In some environment (not ours), this makes
the bundle smaller, as the bundler doesn’t need to bundle type-only
imports anymore.

## Type of change

- Chore (housekeeping or task changes that don't impact user perception)


## How Has This Been Tested?

This was tested to not break the build.

### 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
- [x] 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
- [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:
- [ ] Test plan has been approved by relevant developers
- [ ] Test plan has been peer reviewed by QA
- [ ] Cypress test cases have been added and approved by either SDET or
manual QA
- [ ] Organized project review call with relevant stakeholders after
Round 1/2 of QA
- [ ] Added Test Plan Approved label after reveiwing all Cypress test

---------

Co-authored-by: Satish Gandham <hello@satishgandham.com>
Co-authored-by: Satish Gandham <satish.iitg@gmail.com>
2023-03-16 17:11:47 +05:30
Aishwarya-U-R
72f627932a
test: Script updates for flaky tests (#20846)
## Description

- This PR fixes the flakes from below specs:
- Binding/SmartSubstitutionWidgets_spec.js
- /Git/GitDiscardChange/DiscardChanges_spec.js
- /Widgets/Chart/Custom_Chart_spec.js
- /Checkbox/CheckboxGroup_withQuery_spec.js
- Workspace/MemberRoles_Spec.ts

## Type of change

- Script updates


## How Has This Been Tested?
- Cypress CI runs

## Checklist:
### QA activity:
- [x] Added Test Plan Approved label after reviewing all changes
2023-02-22 11:31:25 +05:30
Vijetha-Kaja
a2afc8c4d9
test: Cypress Flaky fixes + Mock api update + PgAdminspec fix (#20032)
## Description

- Fixed PgAdminspec 

**Fixed below flaky tests**
- PgAdmin_spec.ts
- CreateNewApp_spec.js
- DatasourceSchema_spec.ts
- Tab_spec.js
- GitBugs_spec.js
- Fork_Template_Existing_app_spec.js
- Fork_Template_To_App_spec.js
- Fork_Template_spec.js
- Scrolling_Spec.ts
- APIOnLoad_Spec.ts
- SetTimeout_spec.ts

**Updated git helper methods**
- MongoDBShoppingCart_spec.js
- GitImport_spec.js
- Deploy_spec.js
- DisconnectGit_spec.js
- GitBugs_spec.js
- RepoLimitExceededErrorModal_spec.js
- ForkTemplateToGitConnectedApp.js

**Modified mock api url and refactored below specs accordingly**
- PromisesApp_spec.js
- Autocomplete_JS_spec.ts
- Bug16377_spec.ts
- InputTruncateCheck_Spec.ts
- Refactoring_spec.ts
- FilePickerV2_spec.js
- CurlImportFlow_spec.js
- SetTimeout_spec.ts

## Type of change

- Flaky test fix

## How Has This Been Tested?
- Cypress test runs

## Checklist:
### QA activity:
- [ ] Test plan has been approved by relevant developers
- [ ] Test plan has been peer reviewed by QA
- [ ] Cypress test cases have been added and approved by either SDET or
manual QA
- [ ] Organized project review call with relevant stakeholders after
Round 1/2 of QA
- [ ] Added Test Plan Approved label after reveiwing all Cypress test

---------

Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2023-02-02 13:29:24 +05:30
Aishwarya-U-R
7596dfc35a
test: Script updates for flaky tests to unblock CI (#17264) 2022-10-03 15:25:11 +05:30
Aishwarya-U-R
06cd7542f5
test: Script updates for flaky tests (#16455)
* UUID table load time increase

* Autocomplete js api failiure fix

* mysql crud fix

* MySQL, Postgres CRUD updates

* flaky fix

* flaky fix

* Upgrade Appsmith spec - moved

* MySQL CRUD spec split

* fix

* fix

* fix

* fix

* Postgres CRUD spec split

* Postgres CRUD spec split

* fix

* EE names update

* fix

* fix
2022-09-05 15:24:56 +05:30
Aishwarya-U-R
3b90baf1d8
test: Script updates for flaky fixes (#16289)
* Auto completre fix

* Toast fixes

* Autocomplete js fix

* datatree mutation spec update

* Datatree -added  running api

* rmeoved unused ref

* Deletion time added

* Community issues spec fix

* AssertImportToast() update

* QueryAbort case fix

* Signature fix

* update

* UUID flaky fix

* Pomises spec + toasts updates

* Toasts updates

* ErrorReporting spec fix

* Scrolling mockdb fix

* Bug tests name change for easy identification

* bug spec file name update

* JSfunc fix

* Community issues table load time increase

* AssertContains() reduced wiat time

* AssertContains() update

* timeout added to mysql crud

* AssertContains revert

* AllInputWidget trial fix

* wait until table load ReadTableRowColumnData()

* fix

* testTimeout added

* ReadTableRowColumnData() revert

* path fix

* WaitUntilTableLoad() revert

* COmmunity issues row select fix

* Faker added

* wait time add for multiselect

* Mulipart fix

* Community issues spec fix

* AllInput spec update

* timeout 1 to 3

* update

* update

* EnterJSContext from JSEditor to PropPane ts

* update

* Removed unwanted comments

* fix

* UUID fix
2022-08-27 18:10:11 +05:30
Aishwarya-U-R
d0dd080397
test: Script fix for Cypress Timeout - CI runs (#15878) 2022-08-10 21:36:30 +05:30
Aishwarya-U-R
10fe3e3acf
Automated tests for Postgres Datatype - JSON type (#14796) 2022-07-06 11:24:00 +05:30
Nidhi
906a7298dc
feat: Simplified Google Sheets queries (#14869)
* Client changes 1

* add DSL functionality

* Temp commit for refactoring changes

* Do I even know what I'm doing here?

* chore: Second GS layout

* Update: Visibility conditional outputs for schemas

- Added the output from conditional outputs for schema children too

* Update: Entity selector visibility control

- Added logic for controlling visibility of sub components via the JS expressions system

* Update: Passing disabled prop to toggle button

* Update: Passing disabled prop to toggle btn

* Update: Styled component for toggle button

- Added disabled styles based on the disabled prop sent to the toggle form view JSON button

* Update: configProperty role in Entity Selector

- Removed dependance of the configProperty of the entity selector children to it's parent component

* Update: type of placeholder key

- Made placeholder key from form config JSON to accept either string or an object
- Earlier only string was accepted
- This is for pagination component

* Update: Added placeholder control for pagination

* Client changes 1

* add DSL functionality

* Do I even know what I'm doing here?

* fix: updated uqi forms ui, clubbed JS switch button to ads, updated tooltip design

* fix: updated tooltip component for wrong ui on entity explore

* temp triggers

* fix: updated uqi forms ui, clubbed JS switch button to ads, updated tooltip design (#12395)

* fix: updated uqi forms ui, clubbed JS switch button to ads, updated tooltip design

* fix: updated tooltip component for wrong ui on entity explore

* fix: updated tooltip ui, where condition placement, sort by ui

* temp form data access logic

* fix: updated sorting type width ui

* fix: updated ui for spacing, width and text issues

* Update: Type for tooltip of UQI forms

- Added option to send an object to the tooltipText object.
- This allows for composite components like pagination to have tooltips for each sub component

* Update: tooltip for pagination component

- Added handling to parse the tooltip for multiple components.
- This allows for composite components like pagination to have tooltips for each sub component

* Update: Type cast for tooltip component

- Made the content passed to tooltip component as a string only

* Update: Fixed tooltip component CSS

* Update: Dropdown option component

- Added a tooltip wrapper to each option
- This is to show on hover text like disabled state

* fix: updated ẇhere clause broken ui for condition

* Add: functions to check and extract expressions

- Loop through the formConfig and find any keys that have a value that is bindable
- Used pre defined regex to check if value is a moustache binding

* Add: Types for evaluated form configs

- Added types for the form configs to be evaluated and their output post eval

* Add: Flow to run the form config

- Run the form config and update the result to the redux state

* Update: Name of the type for formconfigs

- Updated since it was clashing with a component of the same name

* Add: Function to enforce config type checks

- This is done so that the improper configs can be weeded out and the rest of the form can be shown

* Add: Function to update evaluated config

- Added option to update the config if it's values needed evaluation

* Add: Type check for schema sections

* Update: Error handling for invalid control type

- We were throwing an exception till now, changed it to a warning text

* Add: Exposed tooltip for dropdown option disabled state

* Update: switch to json mode functionality

- Added logic to convert data to a string rather than an object when the first switch to JSON mode happens

* Update: Added key to tooltip for dropdown options

* Trigger API modification

* Add: function to fetch default trigger URL

* Update: Made URL optional in dynamic trigger config

* Update: Dynamic trigger API call

- Made the API call for dynamic triggers have URL as optional field
- Added type check to the response of the API call

* Update: resp type for trigger APIs

* Update: Moved code to utils folder

- Moved functions for UQI form eval processing to utils file

* Update: passing original controltype to JS switch

* Update: config for JSON editor mode

- Updated the config to have different options for JSON mode depending on the original control type

* Update: Connected line numbers flag to config

* Revert: CSS changes for tooltip

* Refactor: Removed consle

* Add: type for the config of dynamic values

* Add: Feature to evaluate config for triggers

* Refactor: fix type check errors

* fix: dropdown ui width with text alignment

* Update: fixed selector for dynamic values

* Update: selector call for fetchDynamicValues

* Add table header index prop for columns selector

* migration partial commit

* migration partial commit

* Refactor: removed unused import

* Update: reused function for checking dynamic value

* Update: removed unused import

* Fix format JSON issues

* Retrieve binding paths from entity selector components

* Fixes 6 remaining issues with UQI implementation

* Fix dropdown issues

* Fix dropdown height issues and fixes triggering of APIs when option is deselected

* Migration changes

* Fix QA generated UQI issues

* Fix projection component height and route change logic

* Fix multi select dropdown placeholder text issue and json stringify issue with switching view types

* Reset entity type value when command value changes

* Test changes

* Review comments

* Moved migrations around

* Corrected import statement

* Added JSON schema migration

* Updated schema version

* perf improvements and filter dropdown options feature

* Fix Code mirror component config for toggleComponentToJson input fields.

* Fix prettier issues

* fix prettier issues

* Fix style issues as a result of the merged conflicts

* Fix failing test case

* Fixed a few other flows (#14225)

* Fixed a few other flows

* Review comments

* Fix generate CRUD, fix evaluation of dynamic bindings and fix various styling issues.

* More fixes (#14367)

* Factor in the root formconfig parent key.

* Fix flickering issues, and evaluatedFormConfig issues

* fix: Teeny bugs (#14455)

* Teeny bugs

* Added previous functionality as is

* Improvements in the way we fetch dynamic values

* Fix stringiification issue and cyclic dependency issues

* Resolve projection component values deletion

* Resolve merge conflicts and fix prettier issues

* fix: Tsc issues

* Fix property pane connection navigation

* updating ee locator

* updating inputfield locator

* dropdown locator update

* Merge conflict not properly resolved.

* Fix s3 spec

* Fix Mongo Spec

* Fix some more tests

* fix: prevent cyclic dependency when switching to js mode (#14668)

* add delete events for change from array to string in diff

* add test to assert absence of cyclic dependency error when switching to js in switchgroup widget

* Assert that evaluation is not disabled when no cyclic dependency happens

* Cypress test preparations for google sheets and form controls

* Fixed a few test errors (#14874)

* Add: unit tests for uqi UI updates

- view type tests
- conditional output extraction
- processing conditional output to handle view/enabled state of the component

* Add: completed isValidFormConfig test

* Update: improved tests for update config

- These tests cover the functionality to update a section config after it's components are done evaluating

* Fix failing cypress tests and cyclic dependency issue

* Fixes some more tests

* Fixed migration of row objects (#14896)

* Bumped the version of design system package

* Update: reverted change to EE selector

* Fix deletion pointer

* Update: selector for js on load spec

- Synced with changes related to ADS dropdown

* Fix mongoDBShoppingCart spec

* Remove comments

* Fix: mongo shopping cart test failures

* fix: mongo shopping cart spec

* Dummy push to retrigger vercel

* fix: mongo shopping cart spec

* Update MongoDBShoppingCart_spec.js

* fix: removed unused click away

* dummy commit

* Update: moved helper functions to separate file

* Add: added tests for saga functions

- Worked on testing for
   - extractFetchDynamicValueFormConfigs
   - extractQueueOfValuesToBeFetched

* Add if check for queueOfValuesToBeFetched

* Resolve review comments

* Empty-Commit

Co-authored-by: Irongade <adeoluayangade@yahoo.com>
Co-authored-by: Ayush Pahwa <ayush@appsmith.com>
Co-authored-by: Aman Agarwal <aman@appsmith.com>
Co-authored-by: Ayangade Adeoluwa <37867493+Irongade@users.noreply.github.com>
Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
Co-authored-by: Favour Ohanekwu <fohanekwu@gmail.com>
Co-authored-by: Albin <albin@appsmith.com>
2022-07-04 11:13:27 +05:30
Rishabh Rathod
5625784829
fix: reset meta to default value (#14468)
* fix: [WIP] reset meta to default value

* refactor

* fix reset child widget and type in metaReducer

* Fix type and refactor test

* fix multiselect click

* Add jest test for reset widget action

* Add cypress test

* Add comments

* Add more cases as per comment

* remove `only` from test case

* Add default value case of array with values

* MultiSelect spec fix

* fix currencyInput reset

* refactor test code suggested in comments

* fix type

* fix more type

* fix cypress test

Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2022-06-25 11:00:54 +05:30
Aishwarya-U-R
5d75a46df1
test: Automated tests for Bug #14299 + Specs rearranged (#14632)
* Moving tests

* Workspace cases moved all to one folder

* Moving tests

* Bug 14299 scripted

* JSOnload spec failure fix

* Moving spec

* Moving specs

* Moving specs

* Added bug id in title

* Moving specs

* Moving specs

* Moving spec

* Added bug id in title

* Removed tests

* Theme Basic spec - added publish mode validations

* tests re-arranged

* Theme_form widget fix

* endp to endpoint change

* theme Basic spec fix

* AppSetupForRename removed

* Appli rename reverted

* Specs rearranged

* Added interval validation

* Also deleting query

* validation moved places

* Git imports corrected

* git import corrected

* datePicker fix
2022-06-23 20:43:15 +05:30
Aishwarya-U-R
d7eb5c58fc
Automated tests for Postgres Datatype - Numeric, Character (#14481) 2022-06-16 12:20:02 +05:30
Aishwarya-U-R
43cba21013
test: Automated tests for improved CRUD with JSONFrom - Postgres Ds (#14271)
* Postgres CRUD

* MySQL CI run fix

* Added wait time to DeployApp()

* Helpers Enhancements

* ChangeTheme CRUD

* Postgres CRUD

* Postgres CRUD updated

* Postgres CRUD updates

* Postgres CRUD fix

* Postgres CRUD update

* postgres CRUD update

* Postgress CRUD fix

* setting cypress video false

* ExecuteAction spec fixed

* Postgres case #13 fix

* postgres CRUD fix

* Postgres CRUD fixes

* cypress video - true, reattempt - 1

* failure fixes

* Bug 11529 script added

* Bug 11529 scripted + failure fixes

* JSOnLoad_spec failure fix

* OnLoadActions failure fix

* Failure fixes

* ReadTable increased timeout

* JSFunctionExecution_spec failure fix

* Removed duplicate cases

* Mongo failure fixes + applying theme

* Mongo Spec - Added Deletion of DS also

* Deleting initial page

* Deleting DS Validation added

* tc desc updated

* failure point fixes
2022-06-10 19:00:59 +05:30
Aishwarya-U-R
6c1c5581e7
Automated tests for improved CRUD with JSONFrom - MySQL Ds (#14014) 2022-05-31 11:03:59 +05:30