Skip to content

Commit

Permalink
lint error resolved
Browse files Browse the repository at this point in the history
  • Loading branch information
NandanAnantharamu committed May 21, 2024
1 parent eea09eb commit 19dadff
Showing 1 changed file with 12 additions and 5 deletions.
17 changes: 12 additions & 5 deletions app/client/cypress/support/Pages/AggregateHelper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -302,8 +302,8 @@ export class AggregateHelper {
return exists === "noVerify"
? locator // Return the locator without verification if exists is "noVerify"
: exists === "exist"
? locator.should("have.length.at.least", 1)
: locator.should("have.length", 0);
? locator.should("have.length.at.least", 1)
: locator.should("have.length", 0);
}

public GetNAssertElementText(
Expand Down Expand Up @@ -1835,27 +1835,34 @@ export class AggregateHelper {

public selectAndValidateWidgetNameAndProperty({
clickOptions = {},
widgetName,
widgetType = EntityType.Widget,
hierarchy = [],
propFieldName,
valueToValidate,
toggleEle = null,
valueToValidate,
widgetName,
widgetType = EntityType.Widget,
}: SelectAndValidateParams) {
// Select the widget by name, type, and hierarchy with optional click options
EditorNavigator.SelectEntityByName(
widgetName,
widgetType,
clickOptions,
hierarchy,
);

// Assert that the Property Pane title matches the widget name
this.AssertText(
ObjectsRegistry.PropertyPane._paneTitle,
"text",
widgetName,
);

// If a toggle element is provided, toggle its JavaScript mode
if (toggleEle) {
ObjectsRegistry.PropertyPane.ToggleJSMode(toggleEle);
}

// Validate that the property field value matches the expected value
ObjectsRegistry.PropertyPane.ValidatePropertyFieldValue(
propFieldName,
valueToValidate,
Expand Down

0 comments on commit 19dadff

Please sign in to comment.