diff --git a/README.md b/README.md
index 4a40d6bdc7..92d696f085 100644
--- a/README.md
+++ b/README.md
@@ -208,8 +208,8 @@ Lets build great software together.
[](https://github.com/dhruvikn)
[](https://github.com/megaconfidence)
[](https://github.com/tanvibhakta)
-[](https://github.com/sondermanish)
[](https://github.com/NilanshBansal)
+[](https://github.com/sondermanish)
[](https://github.com/rajatagrawal)
[](https://github.com/subrata71)
[](https://github.com/Druthi)
@@ -315,19 +315,19 @@ Lets build great software together.
[](https://github.com/akshayrangasaid)
[](https://github.com/mojtab23)
[](https://github.com/iamrkcheers)
-[](https://github.com/iamakulov)
[](https://github.com/sumanthyedoti)
[](https://github.com/vaibh1297)
[](https://github.com/vnodecg)
+[](https://github.com/iamakulov)
[](https://github.com/pc9795)
[](https://github.com/Rhitottam)
-[](https://github.com/iSatVeerSingh)
[](https://github.com/akshay11298)
[](https://github.com/daniel-shuy)
[](https://github.com/daniloff200)
[](https://github.com/osis)
[](https://github.com/harshitpandey0426)
[](https://github.com/ganganimaulik)
+[](https://github.com/iSatVeerSingh)
[](https://github.com/jyash97)
[](https://github.com/ram-primathon)
[](https://github.com/sub1983)
@@ -398,7 +398,6 @@ Lets build great software together.
[](https://github.com/felixsuarez0727)
[](https://github.com/gitstart)
[](https://github.com/harshmange44)
-[](https://github.com/indrajitbnikam)
[](https://github.com/ishaanmehta4)
[](https://github.com/jaikanthjay46)
[](https://github.com/jarimayenburg)
diff --git a/app/client/cypress.config.ts b/app/client/cypress.config.ts
index 32f80cda99..fb865a0d32 100644
--- a/app/client/cypress.config.ts
+++ b/app/client/cypress.config.ts
@@ -27,8 +27,8 @@ export default defineConfig({
e2e: {
baseUrl: "https://dev.appsmith.com/",
env: {
- USERNAME: "XXXX",
- PASSWORD: "XXXX",
+ USERNAME: "xxxx",
+ PASSWORD: "xxx",
},
setupNodeEvents(on, config) {
return require("./cypress/plugins/index.js")(on, config);
diff --git a/app/client/cypress/e2e/Regression/Apps/PromisesApp_spec.js b/app/client/cypress/e2e/Regression/Apps/PromisesApp_spec.js
index b7a40718d0..395c85384c 100644
--- a/app/client/cypress/e2e/Regression/Apps/PromisesApp_spec.js
+++ b/app/client/cypress/e2e/Regression/Apps/PromisesApp_spec.js
@@ -3,6 +3,7 @@ import {
entityExplorer,
jsEditor,
apiPage,
+ tedTestConfig,
} from "../../../support/Objects/ObjectsCore";
const commonlocators = require("../../../locators/commonlocators.json");
@@ -12,11 +13,10 @@ describe("JSEditor tests", function () {
});
it("1. Testing promises with resetWidget, storeValue action and API call", () => {
- cy.fixture("datasources").then((datasourceFormData) => {
- apiPage.CreateAndFillApi(datasourceFormData["mockApiUrl"], "TC1api");
- apiPage.RunAPI();
- jsEditor.CreateJSObject(
- `export default {
+ apiPage.CreateAndFillApi(tedTestConfig.mockApiUrl, "TC1api");
+ apiPage.RunAPI();
+ jsEditor.CreateJSObject(
+ `export default {
myFun1: async () => { //comment
await this.clearStore() //clear store value before running the case
return resetWidget('Switch1')
@@ -43,51 +43,51 @@ describe("JSEditor tests", function () {
})
}
}`,
- {
- paste: true,
- completeReplace: true,
- toRun: false,
- shouldCreateNewJSObj: true,
- },
- );
- entityExplorer.SelectEntityByName("Page1", "Pages");
- cy.wait(2000);
- // verify text in the text widget
- cy.get(".t--draggable-textwidget span")
- .eq(5)
- .invoke("text")
- .then((text) => {
- expect(text).to.equal(
- "Step 4: Value is Green and will default to undefined",
- );
- });
- // toggle off the switch
- cy.get(".t--switch-widget-active .bp3-control-indicator").click({
- force: true,
+ {
+ paste: true,
+ completeReplace: true,
+ toRun: false,
+ shouldCreateNewJSObj: true,
+ },
+ );
+ entityExplorer.SelectEntityByName("Page1", "Pages");
+ cy.wait(2000);
+ // verify text in the text widget
+ cy.get(".t--draggable-textwidget span")
+ .eq(5)
+ .invoke("text")
+ .then((text) => {
+ expect(text).to.equal(
+ "Step 4: Value is Green and will default to undefined",
+ );
});
- agHelper.AssertContains("Switch widget has changed");
+ // toggle off the switch
+ cy.get(".t--switch-widget-active .bp3-control-indicator").click({
+ force: true,
+ });
+ agHelper.AssertContains("Switch widget has changed");
- // select an option from select widget
- cy.get(".bp3-button.select-button").click({ force: true });
- cy.get(".menu-item-text").eq(2).click({ force: true });
- cy.wait(2000);
- // verify text in the text widget
- cy.get(".t--draggable-textwidget span")
- .eq(5)
- .invoke("text")
- .then((text) => {
- expect(text).to.equal(
- "Step 4: Value is Red and will default to undefined",
- );
- });
- // move to page 2 on table widget
- cy.get(commonlocators.tableNextPage).click();
- cy.get(".t--table-widget-page-input").within(() => {
- cy.get("input.bp3-input").should("have.value", "2");
+ // select an option from select widget
+ cy.get(".bp3-button.select-button").click({ force: true });
+ cy.get(".menu-item-text").eq(2).click({ force: true });
+ cy.wait(2000);
+ // verify text in the text widget
+ cy.get(".t--draggable-textwidget span")
+ .eq(5)
+ .invoke("text")
+ .then((text) => {
+ expect(text).to.equal(
+ "Step 4: Value is Red and will default to undefined",
+ );
});
- cy.wait(3000);
- // hit audio play button and trigger actions
- /* cy.openPropertyPane("audiowidget");
+ // move to page 2 on table widget
+ cy.get(commonlocators.tableNextPage).click();
+ cy.get(".t--table-widget-page-input").within(() => {
+ cy.get("input.bp3-input").should("have.value", "2");
+ });
+ cy.wait(3000);
+ // hit audio play button and trigger actions
+ /* cy.openPropertyPane("audiowidget");
cy.get(widgetsPage.autoPlay).click({ force: true });
cy.wait("@postExecute").should(
"have.nested.property",
@@ -111,7 +111,6 @@ describe("JSEditor tests", function () {
"Success running API query",
"GREEN",
); */
- });
});
//Skipping reason? to add
diff --git a/app/client/cypress/e2e/Regression/ClientSide/ActionExecution/NavigateTo1_spec.ts b/app/client/cypress/e2e/Regression/ClientSide/ActionExecution/NavigateTo1_spec.ts
index bc78b78ba7..24b7eccb88 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/ActionExecution/NavigateTo1_spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/ActionExecution/NavigateTo1_spec.ts
@@ -24,7 +24,6 @@ describe("Navigate To feature", () => {
}
}}`,
);
- agHelper.AssertAutoSave();
agHelper.PopupClose("onClick");
agHelper.ClickButton("Submit");
cy.url().should("include", "a=b").and("include", "test=123");
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Autocomplete/JS_AC1_spec.ts b/app/client/cypress/e2e/Regression/ClientSide/Autocomplete/JS_AC1_spec.ts
index df654505bb..35c7409395 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Autocomplete/JS_AC1_spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/Autocomplete/JS_AC1_spec.ts
@@ -5,6 +5,7 @@ import {
draggableWidgets,
entityExplorer,
entityItems,
+ tedTestConfig,
jsEditor,
locators,
} from "../../../../support/Objects/ObjectsCore";
@@ -172,28 +173,26 @@ describe("Autocomplete tests", () => {
});
it("5. Api data with array of object autocompletion test", () => {
- cy.fixture("datasources").then((datasourceFormData: any) => {
- apiPage.CreateAndFillApi(datasourceFormData["mockApiUrl"]);
- agHelper.Sleep(2000);
- apiPage.RunAPI();
- // Using same js object
- entityExplorer.SelectEntityByName("JSObject1", "Queries/JS");
- agHelper.GetNClick(jsEditor._lineinJsEditor(5), 0, true);
- agHelper.SelectNRemoveLineText(locators._codeMirrorTextArea);
- //agHelper.GetNClick(jsEditor._lineinJsEditor(5));
- agHelper.TypeText(locators._codeMirrorTextArea, "Api1.d");
- agHelper.GetNAssertElementText(locators._hints, "data");
- agHelper.Sleep();
- agHelper.TypeText(locators._codeMirrorTextArea, "ata[0].e");
- agHelper.GetNAssertElementText(locators._hints, "email");
- agHelper.Sleep();
- agHelper.TypeText(locators._codeMirrorTextArea, "mail");
- entityExplorer.SelectEntityByName(jsName as string, "Queries/JS");
- entityExplorer.ActionContextMenuByEntityName({
- entityNameinLeftSidebar: "JSObject1",
- action: "Delete",
- entityType: entityItems.JSObject,
- });
+ apiPage.CreateAndFillApi(tedTestConfig.mockApiUrl);
+ agHelper.Sleep(2000);
+ apiPage.RunAPI();
+ // Using same js object
+ entityExplorer.SelectEntityByName("JSObject1", "Queries/JS");
+ agHelper.GetNClick(jsEditor._lineinJsEditor(5), 0, true);
+ agHelper.SelectNRemoveLineText(locators._codeMirrorTextArea);
+ //agHelper.GetNClick(jsEditor._lineinJsEditor(5));
+ agHelper.TypeText(locators._codeMirrorTextArea, "Api1.d");
+ agHelper.GetNAssertElementText(locators._hints, "data");
+ agHelper.Sleep();
+ agHelper.TypeText(locators._codeMirrorTextArea, "ata[0].e");
+ agHelper.GetNAssertElementText(locators._hints, "email");
+ agHelper.Sleep();
+ agHelper.TypeText(locators._codeMirrorTextArea, "mail");
+ entityExplorer.SelectEntityByName(jsName as string, "Queries/JS");
+ entityExplorer.ActionContextMenuByEntityName({
+ entityNameinLeftSidebar: "JSObject1",
+ action: "Delete",
+ entityType: entityItems.JSObject,
});
});
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Autocomplete/JS_AC2_spec.ts b/app/client/cypress/e2e/Regression/ClientSide/Autocomplete/JS_AC2_spec.ts
index 3e94dcba93..42c76171ee 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Autocomplete/JS_AC2_spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/Autocomplete/JS_AC2_spec.ts
@@ -146,20 +146,28 @@ describe("Autocomplete tests", () => {
agHelper.GetElement(jsEditor._lineinJsEditor(4)).click();
agHelper.WaitUntilAllToastsDisappear();
-
//Assert that hints are not present inside the string
agHelper.TypeText(locators._codeMirrorTextArea, `const x = "`);
-
agHelper.AssertElementAbsence(locators._hints);
- agHelper.SelectNRemoveLineText(jsEditor._lineinJsEditor(4));
-
- //Assert that hints are not present when line is cleared with backspace
- agHelper.AssertElementAbsence(locators._hints);
-
- //Assert that hints are not present when token is a comment
+ //Assert that hints are not present when comment line added into already existing code
+ agHelper.SelectNRemoveLineText(jsEditor._lineinJsEditor(4)); //remove only ""
+ agHelper.AssertElementAbsence(locators._hints); //Assert that hints are not present when line is cleared with backspace
agHelper.TypeText(locators._codeMirrorTextArea, "// showA'");
+ agHelper.AssertElementAbsence(locators._hints);
+ //Check for no showAlert() hint
+ agHelper.GetNClick(jsEditor._lineinJsEditor(4), 0, true);
+ agHelper.SelectNRemoveLineText(locators._codeMirrorTextArea);
+ agHelper.AssertElementAbsence(locators._hints); //Assert that hints are not present when line is removed
+ agHelper.TypeText(locators._codeMirrorTextArea, "// showA");
+ agHelper.AssertElementAbsence(locators._hints); //Assert that hints are not present when token is a comment
+
+ //Check for no hint with any A in it
+ agHelper.GetNClick(jsEditor._lineinJsEditor(4), 0, true);
+ agHelper.SelectNRemoveLineText(locators._codeMirrorTextArea);
+ agHelper.AssertElementAbsence(locators._hints);
+ agHelper.TypeText(locators._codeMirrorTextArea, "// showA'");
agHelper.AssertElementAbsence(locators._hints);
cy.get("@jsObjName").then((jsObjName) => {
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Binding/ButtonWidgets_NavigateTo_validation_spec.js b/app/client/cypress/e2e/Regression/ClientSide/Binding/ButtonWidgets_NavigateTo_validation_spec.js
index 09014dcb6f..1be49319a7 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Binding/ButtonWidgets_NavigateTo_validation_spec.js
+++ b/app/client/cypress/e2e/Regression/ClientSide/Binding/ButtonWidgets_NavigateTo_validation_spec.js
@@ -1,19 +1,19 @@
-const publish = require("../../../../locators/publishWidgetspage.json");
-const testdata = require("../../../../fixtures/testdata.json");
import {
entityExplorer,
propPane,
agHelper,
deployMode,
+ locators,
+ draggableWidgets,
} from "../../../../support/Objects/ObjectsCore";
+const testdata = require("../../../../fixtures/testdata.json");
describe("Binding the button Widgets and validating NavigateTo Page functionality", function () {
before(() => {
- agHelper.AddDsl("buttondsl");
+ entityExplorer.DragDropWidgetNVerify(draggableWidgets.BUTTON);
});
it("1. Button widget with action navigate to page", function () {
- entityExplorer.SelectEntityByName("Button1");
propPane.SelectPlatformFunction("onClick", "Navigate to");
agHelper.GetNClick(propPane._navigateToType("URL"));
cy.get("label")
@@ -22,22 +22,15 @@ describe("Binding the button Widgets and validating NavigateTo Page functionalit
.within(() => {
cy.get(".t--code-editor-wrapper").type(testdata.externalPage);
});
-
- // eslint-disable-next-line cypress/no-unnecessary-waiting
cy.wait(300);
- });
-
- it("2. Button click should take the control to page link validation", function () {
- deployMode.DeployApp();
+ //. Button click should take the control to page link validation", function () {
+ deployMode.DeployApp(locators._widgetInDeployed(draggableWidgets.BUTTON));
cy.wait(2000);
- cy.get(publish.buttonWidget).click();
- // eslint-disable-next-line cypress/no-unnecessary-waiting
- cy.wait(500);
- cy.get(publish.buttonWidget).should("not.exist");
- cy.go("back");
- deployMode.NavigateBacktoEditor();
- cy.wait("@getPage")
- .its("response.body.responseMeta.status")
- .should("eq", 200);
+ agHelper.ClickButton("Submit");
+ cy.wait(2000); //for page to load
+ agHelper.AssertElementAbsence(
+ locators._widgetInDeployed(draggableWidgets.BUTTON),
+ );
+ agHelper.AssertElementVisible(locators._visibleTextSpan("Build the tools"));
});
});
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Binding/JSObjectToListWidget_Spec.ts b/app/client/cypress/e2e/Regression/ClientSide/Binding/JSObjectToListWidget_Spec.ts
index 351194cdb9..1c575764a6 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Binding/JSObjectToListWidget_Spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/Binding/JSObjectToListWidget_Spec.ts
@@ -7,9 +7,7 @@ describe("Validate JSObj binding to Table widget", () => {
});
it("1. Add users api and bind to JSObject", () => {
- cy.fixture("datasources").then((datasourceFormData: any) => {
- _.apiPage.CreateAndFillApi(datasourceFormData["mockApiUrl"]);
- });
+ _.apiPage.CreateAndFillApi(_.tedTestConfig.mockApiUrl);
_.apiPage.RunAPI();
_.agHelper.GetNClick(_.dataSources._queryResponse("JSON"));
_.apiPage.ReadApiResponsebyKey("name");
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Binding/Widgets_Default_data_validation_spec.js b/app/client/cypress/e2e/Regression/ClientSide/Binding/Widgets_Default_data_validation_spec.js
index 9d4a38f786..d18d52a873 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Binding/Widgets_Default_data_validation_spec.js
+++ b/app/client/cypress/e2e/Regression/ClientSide/Binding/Widgets_Default_data_validation_spec.js
@@ -4,6 +4,7 @@ const testdata = require("../../../../fixtures/testdata.json");
import {
entityExplorer,
agHelper,
+ propPane,
} from "../../../../support/Objects/ObjectsCore";
describe("Binding the multiple widgets and validating default data", function () {
@@ -13,21 +14,15 @@ describe("Binding the multiple widgets and validating default data", function ()
it("1. Input widget test with default value from table widget", function () {
entityExplorer.SelectEntityByName("Input1");
- cy.testJsontext("defaultvalue", testdata.defaultInputWidget + "}}");
-
- cy.wait("@updateLayout").should(
- "have.nested.property",
- "response.body.responseMeta.status",
- 200,
+ propPane.UpdatePropertyFieldValue(
+ "Default value",
+ testdata.defaultInputWidget + "}}",
);
//Dropdown widget test with default value from table widget
entityExplorer.SelectEntityByName("Dropdown1");
- cy.testJsontext("options", JSON.stringify(testdata.deafultDropDownWidget));
-
- cy.wait("@updateLayout").should(
- "have.nested.property",
- "response.body.responseMeta.status",
- 200,
+ propPane.UpdatePropertyFieldValue(
+ "Options",
+ JSON.stringify(testdata.deafultDropDownWidget),
);
});
diff --git a/app/client/cypress/e2e/Regression/ClientSide/BugTests/ApiBugs_Spec.ts b/app/client/cypress/e2e/Regression/ClientSide/BugTests/ApiBugs_Spec.ts
index b96dcf0d44..327291e2c0 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/BugTests/ApiBugs_Spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/BugTests/ApiBugs_Spec.ts
@@ -5,9 +5,9 @@ import {
apiPage,
dataSources,
debuggerHelper,
+ tedTestConfig,
} from "../../../../support/Objects/ObjectsCore";
import { Widgets } from "../../../../support/Pages/DataSources";
-import datasourceFormData from "../../../../fixtures/datasources.json";
import {
ERROR_ACTION_EXECUTE_FAIL,
@@ -16,7 +16,7 @@ import {
describe("API Bugs", function () {
it("1. Bug 14037: User gets an error even when table widget is added from the API page successfully", function () {
- apiPage.CreateAndFillApi(datasourceFormData.mockApiUrl, "Api1");
+ apiPage.CreateAndFillApi(tedTestConfig.mockApiUrl, "Api1");
apiPage.RunAPI();
dataSources.AddSuggesstedWidget(Widgets.Table);
@@ -44,7 +44,7 @@ describe("API Bugs", function () {
it("3. Bug 18876 Ensures application does not crash when saving datasource", () => {
apiPage.CreateAndFillApi(
- datasourceFormData.mockApiUrl,
+ tedTestConfig.mockApiUrl,
"FirstAPI",
10000,
"POST",
diff --git a/app/client/cypress/e2e/Regression/ClientSide/BugTests/Bug15056_Spec.ts b/app/client/cypress/e2e/Regression/ClientSide/BugTests/Bug15056_Spec.ts
index aa28daedc4..ea93903ff5 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/BugTests/Bug15056_Spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/BugTests/Bug15056_Spec.ts
@@ -1,10 +1,10 @@
-import { ObjectsRegistry } from "../../../../support/Objects/Registry";
-import datasourceFormData from "../../../../fixtures/datasources.json";
-
-const agHelper = ObjectsRegistry.AggregateHelper;
-const jsEditor = ObjectsRegistry.JSEditor;
-const apiPage = ObjectsRegistry.ApiPage;
-const ee = ObjectsRegistry.EntityExplorer;
+import {
+ tedTestConfig,
+ agHelper,
+ jsEditor,
+ apiPage,
+ entityExplorer,
+} from "../../../../support/Objects/ObjectsCore";
describe("JS data update on button click", function () {
before(() => {
@@ -12,7 +12,7 @@ describe("JS data update on button click", function () {
});
it("1. Populates js function data when triggered via button click", function () {
- apiPage.CreateAndFillApi(datasourceFormData.mockApiUrl, "Api1");
+ apiPage.CreateAndFillApi(tedTestConfig.mockApiUrl, "Api1");
const jsObjectString = `export default {
myVar1: [],
@@ -35,7 +35,7 @@ describe("JS data update on button click", function () {
toRun: false,
shouldCreateNewJSObj: true,
});
- ee.SelectEntityByName("Button2", "Widgets");
+ entityExplorer.SelectEntityByName("Button2", "Widgets");
agHelper.ClickButton("Submit");
agHelper.AssertContains("myFun1 Data", "exist");
agHelper.AssertContains("myFun2 Data", "exist");
diff --git a/app/client/cypress/e2e/Regression/ClientSide/BugTests/Bug16702_Spec.ts b/app/client/cypress/e2e/Regression/ClientSide/BugTests/Bug16702_Spec.ts
index fb61e2bc91..1e0896d775 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/BugTests/Bug16702_Spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/BugTests/Bug16702_Spec.ts
@@ -30,7 +30,7 @@ describe("Binding Expressions should not be truncated in Url and path extraction
shouldCreateNewJSObj: true,
});
- _.apiPage.CreateAndFillGraphqlApi(_.hostPort.GraphqlApiUrl_TED);
+ _.apiPage.CreateAndFillGraphqlApi(_.tedTestConfig.GraphqlApiUrl_TED);
_.dataSources.UpdateGraphqlQueryAndVariable({
query: GRAPHQL_LIMIT_QUERY,
});
diff --git a/app/client/cypress/e2e/Regression/ClientSide/BugTests/CatchBlock_Spec.ts b/app/client/cypress/e2e/Regression/ClientSide/BugTests/CatchBlock_Spec.ts
index 58208f1bbd..9b4e0648fe 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/BugTests/CatchBlock_Spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/BugTests/CatchBlock_Spec.ts
@@ -4,12 +4,12 @@ import {
apiPage,
entityExplorer,
entityItems,
- hostPort,
+ tedTestConfig,
} from "../../../../support/Objects/ObjectsCore";
describe("Bug #15372 Catch block was not triggering in Safari/firefox", () => {
it("1. Triggers the catch block when the API hits a 404", () => {
- apiPage.CreateAndFillApi(hostPort.mockHttpCodeUrl + "404");
+ apiPage.CreateAndFillApi(tedTestConfig.mockHttpCodeUrl + "404");
jsEditor.CreateJSObject(
`export default {
fun: async () => {
diff --git a/app/client/cypress/e2e/Regression/ClientSide/BugTests/GitBugs_Spec.ts b/app/client/cypress/e2e/Regression/ClientSide/BugTests/GitBugs_Spec.ts
index bb302db4ee..47069bd694 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/BugTests/GitBugs_Spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/BugTests/GitBugs_Spec.ts
@@ -1,5 +1,4 @@
import * as _ from "../../../../support/Objects/ObjectsCore";
-import datasourceFormData from "../../../../fixtures/datasources.json";
let repoName: any;
let tempBranch: any;
@@ -16,9 +15,8 @@ describe("Git Bugs", function () {
});
it("1. Bug 16248, When GitSync modal is open, block shortcut action execution", function () {
- const largeResponseApiUrl = datasourceFormData.mockApiUrl;
const modifierKey = Cypress.platform === "darwin" ? "meta" : "ctrl";
- _.apiPage.CreateAndFillApi(largeResponseApiUrl, "GitSyncTest");
+ _.apiPage.CreateAndFillApi(_.tedTestConfig.mockApiUrl, "GitSyncTest");
_.gitSync.OpenGitSyncModal();
cy.get("body").type(`{${modifierKey}}{enter}`);
cy.get("@postExecute").should("not.exist");
diff --git a/app/client/cypress/e2e/Regression/ClientSide/BugTests/InputTruncateCheck_Spec.ts b/app/client/cypress/e2e/Regression/ClientSide/BugTests/InputTruncateCheck_Spec.ts
index 177541ace7..ba212e5b5e 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/BugTests/InputTruncateCheck_Spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/BugTests/InputTruncateCheck_Spec.ts
@@ -10,6 +10,7 @@ import {
apiPage,
draggableWidgets,
fakerHelper,
+ tedTestConfig,
} from "../../../../support/Objects/ObjectsCore";
const widgetsToTest = {
@@ -79,9 +80,7 @@ const widgetsToTest = {
};
function configureApi() {
- cy.fixture("datasources").then((datasourceFormData) => {
- apiPage.CreateAndFillApi(datasourceFormData["mockApiUrl"], "FirstAPI");
- });
+ apiPage.CreateAndFillApi(tedTestConfig.mockApiUrl, "FirstAPI");
apiPage.EnterHeader("value", "{{this.params.value}}");
}
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Git/GitSync/Connection_spec.js b/app/client/cypress/e2e/Regression/ClientSide/Git/GitSync/Connection_spec.js
index a596851073..e21ca7bd10 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Git/GitSync/Connection_spec.js
+++ b/app/client/cypress/e2e/Regression/ClientSide/Git/GitSync/Connection_spec.js
@@ -48,7 +48,7 @@ describe("Git sync modal: connect tab", function () {
cy.get(gitSyncLocators.generateDeployKeyBtn).should("not.exist");
cy.get(gitSyncLocators.gitRepoInput).type(
- `{selectAll}${_.hostPort.GITEA_API_URL_TED}/${repoName}.git`,
+ `{selectAll}${_.tedTestConfig.GITEA_API_URL_TED}/${repoName}.git`,
);
cy.contains(Cypress.env("MESSAGES").PASTE_SSH_URL_INFO()).should(
"not.exist",
@@ -104,7 +104,7 @@ describe("Git sync modal: connect tab", function () {
cy.get(gitSyncLocators.connectSubmitBtn).should("be.disabled");
cy.get(gitSyncLocators.gitRepoInput).type(
- `{selectAll}${_.hostPort.GITEA_API_URL_TED}/${repoName}.git`,
+ `{selectAll}${_.tedTestConfig.GITEA_API_URL_TED}/${repoName}.git`,
);
cy.contains(Cypress.env("MESSAGES").PASTE_SSH_URL_INFO()).should(
"not.exist",
@@ -200,7 +200,7 @@ describe("Git sync modal: connect tab", function () {
cy.get(gitSyncLocators.gitRepoInput)
.scrollIntoView()
- .type(`{selectAll}${_.hostPort.GITEA_API_URL_TED}/${repoName}.git`, {
+ .type(`{selectAll}${_.tedTestConfig.GITEA_API_URL_TED}/${repoName}.git`, {
force: true,
});
cy.get(gitSyncLocators.connectSubmitBtn).scrollIntoView().click();
@@ -213,7 +213,7 @@ describe("Git sync modal: connect tab", function () {
cy.get(gitSyncLocators.gitRepoInput)
.scrollIntoView()
- .type(`{selectAll}${_.hostPort.GITEA_API_URL_TED}/${repoName}.git`, {
+ .type(`{selectAll}${_.tedTestConfig.GITEA_API_URL_TED}/${repoName}.git`, {
force: true,
});
@@ -234,7 +234,7 @@ describe("Git sync modal: connect tab", function () {
cy.request({
method: "POST",
- url: `${_.hostPort.GITEA_API_BASE_TED}:${_.hostPort.GITEA_API_PORT_TED}/api/v1/repos/Cypress/${repoName}/keys`,
+ url: `${_.tedTestConfig.GITEA_API_BASE_TED}:${_.tedTestConfig.GITEA_API_PORT_TED}/api/v1/repos/Cypress/${repoName}/keys`,
headers: {
Authorization: `token ${Cypress.env("GITEA_TOKEN")}`,
},
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Git/GitSync/GitBugs_spec.js b/app/client/cypress/e2e/Regression/ClientSide/Git/GitSync/GitBugs_spec.js
index 1318f07625..8d91033c8c 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Git/GitSync/GitBugs_spec.js
+++ b/app/client/cypress/e2e/Regression/ClientSide/Git/GitSync/GitBugs_spec.js
@@ -4,7 +4,7 @@ import homePageLocators from "../../../../../locators/HomePage";
import {
agHelper,
entityExplorer,
- hostPort,
+ tedTestConfig,
gitSync,
homePage,
jsEditor,
@@ -286,7 +286,7 @@ describe("Git sync Bug #10773", function () {
`generateKey-${repoName}`,
);
cy.get(gitSyncLocators.gitRepoInput).type(
- `{selectAll}${hostPort.GITEA_API_URL_TED}/${repoName}.git`,
+ `{selectAll}${tedTestConfig.GITEA_API_URL_TED}/${repoName}.git`,
);
// abort git flow after generating key
cy.get(gitSyncLocators.closeGitSyncModal).click();
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Linting/BasicLint_spec.ts b/app/client/cypress/e2e/Regression/ClientSide/Linting/BasicLint_spec.ts
index 3bf237ab8a..d60465513d 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Linting/BasicLint_spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/Linting/BasicLint_spec.ts
@@ -9,8 +9,8 @@ import {
locators,
propPane,
entityItems,
+ tedTestConfig,
} from "../../../../support/Objects/ObjectsCore";
-import datasourceFormData from "../../../../fixtures/datasources.json";
const successMessage = "Successful Trigger";
const errorMessage = "Unsuccessful Trigger";
@@ -80,7 +80,7 @@ describe("Linting", () => {
clickButtonAndAssertLintError(true);
// create Api1
- apiPage.CreateAndFillApi(datasourceFormData.mockApiUrl);
+ apiPage.CreateAndFillApi(tedTestConfig.mockApiUrl);
clickButtonAndAssertLintError(false);
@@ -94,7 +94,7 @@ describe("Linting", () => {
clickButtonAndAssertLintError(true);
// Re-create Api1
- apiPage.CreateAndFillApi(datasourceFormData.mockApiUrl);
+ apiPage.CreateAndFillApi(tedTestConfig.mockApiUrl);
clickButtonAndAssertLintError(false);
});
@@ -295,7 +295,7 @@ describe("Linting", () => {
shouldCreateNewJSObj: true,
},
);
- apiPage.CreateAndFillApi(datasourceFormData.mockApiUrl);
+ apiPage.CreateAndFillApi(tedTestConfig.mockApiUrl);
createMySQLDatasourceQuery();
agHelper.RefreshPage(); //Since this seems failing a bit
@@ -404,11 +404,11 @@ describe("Linting", () => {
myFun1 () {
// write code here
// this.myVar1 = [1,2,3]
-
+
},
async myFun1 () {
// use async-await or promises
- // await storeValue('varName', 'hello world')
+ // await storeValue('varName', 'hello world')
}
}`;
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Linting/EntityPropertiesLint_spec.ts b/app/client/cypress/e2e/Regression/ClientSide/Linting/EntityPropertiesLint_spec.ts
index a103ff8806..6e48294d71 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Linting/EntityPropertiesLint_spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/Linting/EntityPropertiesLint_spec.ts
@@ -7,8 +7,8 @@ import {
apiPage,
draggableWidgets,
locators,
+ tedTestConfig,
} from "../../../../support/Objects/ObjectsCore";
-import datasourceFormData from "../../../../fixtures/datasources.json";
describe("Linting of entity properties", () => {
before(() => {
@@ -19,7 +19,7 @@ describe("Linting of entity properties", () => {
it("1. Shows correct lint error when wrong Api property is binded", () => {
const invalidProperty = "unknownProperty";
// create Api1
- apiPage.CreateAndFillApi(datasourceFormData.mockApiUrl);
+ apiPage.CreateAndFillApi(tedTestConfig.mockApiUrl);
// Edit Button onclick property
entityExplorer.SelectEntityByName("Button1", "Widgets");
propPane.EnterJSContext(
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Onboarding/GuidedTour_spec.js b/app/client/cypress/e2e/Regression/ClientSide/Onboarding/GuidedTour_spec.js
index f09ccb5429..6e5d5e3df4 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Onboarding/GuidedTour_spec.js
+++ b/app/client/cypress/e2e/Regression/ClientSide/Onboarding/GuidedTour_spec.js
@@ -42,7 +42,12 @@ describe("excludeForAirgap", "Guided Tour", function () {
entityExplorer.SelectEntityByName("CustomersTable");
// Step 3: Add binding to the tableData property
- propPane.UpdatePropertyFieldValue("Table data", "{{getCustomers.data}}");
+ propPane.UpdatePropertyFieldValue(
+ "Table data",
+ "{{getCustomers.data}}",
+ true,
+ false,
+ );
cy.get(guidedTourLocators.successButton).click();
cy.get(guidedTourLocators.infoButton).click();
// Renaming widgets // Commending below wait due to flakiness
diff --git a/app/client/cypress/e2e/Regression/ClientSide/OtherUIFeatures/ApplicationURL_spec.js b/app/client/cypress/e2e/Regression/ClientSide/OtherUIFeatures/ApplicationURL_spec.js
index 1a8f72ea55..2699da1f5e 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/OtherUIFeatures/ApplicationURL_spec.js
+++ b/app/client/cypress/e2e/Regression/ClientSide/OtherUIFeatures/ApplicationURL_spec.js
@@ -1,6 +1,7 @@
import homePageLocators from "../../../../locators/HomePage";
const explorer = require("../../../../locators/explorerlocators.json");
import {
+ assertHelper,
entityExplorer,
homePage,
} from "../../../../support/Objects/ObjectsCore";
@@ -30,13 +31,8 @@ describe("Slug URLs", () => {
it("2. Checks if application slug updates on the URL when application name changes", () => {
cy.generateUUID().then((appName) => {
applicationName = appName;
- cy.AppSetupForRename();
- cy.get(homePageLocators.applicationName).type(`${appName}` + "{enter}");
- cy.wait("@updateApplication").should(
- "have.nested.property",
- "response.body.responseMeta.status",
- 200,
- );
+ homePage.RenameApplication(applicationName);
+ assertHelper.AssertNetworkStatus("updateApplication");
cy.location("pathname").then((pathname) => {
const pageId = pathname.split("/")[3]?.split("-").pop();
expect(pathname).to.be.equal(`/app/${appName}/page1-${pageId}/edit`);
diff --git a/app/client/cypress/e2e/Regression/ClientSide/OtherUIFeatures/EntityBottomBar_spec.ts b/app/client/cypress/e2e/Regression/ClientSide/OtherUIFeatures/EntityBottomBar_spec.ts
index d2afc8b177..7c3f20e81b 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/OtherUIFeatures/EntityBottomBar_spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/OtherUIFeatures/EntityBottomBar_spec.ts
@@ -37,27 +37,25 @@ describe("Entity bottom bar", () => {
});
it("3. Api bottom pane should be collapsable", () => {
- cy.fixture("datasources").then((datasourceFormData: any) => {
- _.entityExplorer.NavigateToSwitcher("Explorer");
- _.apiPage.CreateAndFillApi(datasourceFormData["mockApiUrl"]);
- //Verify if bottom bar opens on clicking debugger icon in api page.
- _.debuggerHelper.ClickDebuggerIcon();
- _.debuggerHelper.AssertOpen(PageType.API);
- //Verify if selected tab is errors in tab title.
- _.debuggerHelper.AssertSelectedTab("Errors");
- //Verify if bottom bar is closed on clicking close icon in API page.
- _.debuggerHelper.CloseBottomBar();
- _.debuggerHelper.AssertClosed();
- //Verify if bottom bar opens on clicking debugger icon in api page.
- _.debuggerHelper.ClickDebuggerIcon();
- _.debuggerHelper.AssertOpen(PageType.API);
- //Verify if bottom bar is open on executing api.
- _.apiPage.RunAPI();
- _.agHelper.Sleep(1000);
- _.debuggerHelper.AssertOpen(PageType.API);
- //verify if response tab is selected on execution api.
- _.debuggerHelper.AssertSelectedTab("Response");
- });
+ _.entityExplorer.NavigateToSwitcher("Explorer");
+ _.apiPage.CreateAndFillApi(_.tedTestConfig.mockApiUrl);
+ //Verify if bottom bar opens on clicking debugger icon in api page.
+ _.debuggerHelper.ClickDebuggerIcon();
+ _.debuggerHelper.AssertOpen(PageType.API);
+ //Verify if selected tab is errors in tab title.
+ _.debuggerHelper.AssertSelectedTab("Errors");
+ //Verify if bottom bar is closed on clicking close icon in API page.
+ _.debuggerHelper.CloseBottomBar();
+ _.debuggerHelper.AssertClosed();
+ //Verify if bottom bar opens on clicking debugger icon in api page.
+ _.debuggerHelper.ClickDebuggerIcon();
+ _.debuggerHelper.AssertOpen(PageType.API);
+ //Verify if bottom bar is open on executing api.
+ _.apiPage.RunAPI();
+ _.agHelper.Sleep(1000);
+ _.debuggerHelper.AssertOpen(PageType.API);
+ //verify if response tab is selected on execution api.
+ _.debuggerHelper.AssertSelectedTab("Response");
});
it("4. Bottom bar in Datasource", () => {
diff --git a/app/client/cypress/e2e/Regression/ClientSide/PeekOverlay/PeekOverlay_Spec.ts b/app/client/cypress/e2e/Regression/ClientSide/PeekOverlay/PeekOverlay_Spec.ts
index 0fb9afdbfb..763934f3d1 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/PeekOverlay/PeekOverlay_Spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/PeekOverlay/PeekOverlay_Spec.ts
@@ -2,133 +2,131 @@ import * as _ from "../../../../support/Objects/ObjectsCore";
describe("Peek overlay", () => {
it("1. Main test", () => {
- cy.fixture("datasources").then((datasourceFormData: any) => {
- _.entityExplorer.DragDropWidgetNVerify("tablewidgetv2", 500, 100);
- _.entityExplorer.NavigateToSwitcher("Explorer");
- _.table.AddSampleTableData();
- _.apiPage.CreateAndFillApi(datasourceFormData["mockApiUrl"]);
- _.apiPage.RunAPI();
- _.apiPage.CreateAndFillApi(datasourceFormData["mockApiUrl"]);
- _.jsEditor.CreateJSObject(JsObjectContent, {
- paste: true,
- completeReplace: true,
- toRun: false,
- shouldCreateNewJSObj: true,
- lineNumber: 0,
- prettify: true,
- });
- _.jsEditor.SelectFunctionDropdown("myFun2");
- _.jsEditor.RunJSObj();
- _.agHelper.Sleep();
- _.debuggerHelper.CloseBottomBar();
-
- // check number array
- _.peekOverlay.HoverCode(8, 3, "numArray");
- _.peekOverlay.IsOverlayOpen();
- _.peekOverlay.VerifyDataType("array");
- _.peekOverlay.CheckPrimitveArrayInOverlay([1, 2, 3]);
- _.peekOverlay.ResetHover();
-
- // check basic object
- _.peekOverlay.HoverCode(9, 3, "objectData");
- _.peekOverlay.IsOverlayOpen();
- _.peekOverlay.VerifyDataType("object");
- _.peekOverlay.CheckBasicObjectInOverlay({ x: 123, y: "123" });
- _.peekOverlay.ResetHover();
-
- // check null - with this keyword
- _.peekOverlay.HoverCode(10, 3, "nullData");
- _.peekOverlay.IsOverlayOpen();
- _.peekOverlay.VerifyDataType("null");
- _.peekOverlay.CheckPrimitiveValue("null");
- _.peekOverlay.ResetHover();
-
- // check number
- _.peekOverlay.HoverCode(11, 3, "numberData");
- _.peekOverlay.IsOverlayOpen();
- _.peekOverlay.VerifyDataType("number");
- _.peekOverlay.CheckPrimitiveValue("1");
- _.peekOverlay.ResetHover();
-
- // check boolean
- _.peekOverlay.HoverCode(12, 3, "isLoading");
- _.peekOverlay.IsOverlayOpen();
- _.peekOverlay.VerifyDataType("boolean");
- _.peekOverlay.CheckPrimitiveValue("false");
- _.peekOverlay.ResetHover();
-
- // TODO: handle this function failure on CI tests -> "function(){}"
- // check function
- // _.peekOverlay.HoverCode(13, 3, "run");
- // _.peekOverlay.IsOverlayOpen();
- // _.peekOverlay.VerifyDataType("function");
- // _.peekOverlay.CheckPrimitiveValue("function () {}");
- // _.peekOverlay.ResetHover();
-
- // check undefined
- _.peekOverlay.HoverCode(14, 3, "data");
- _.peekOverlay.IsOverlayOpen();
- _.peekOverlay.VerifyDataType("undefined");
- _.peekOverlay.CheckPrimitiveValue("undefined");
- _.peekOverlay.ResetHover();
-
- // check string
- _.peekOverlay.HoverCode(15, 3, "mode");
- _.peekOverlay.IsOverlayOpen();
- _.peekOverlay.VerifyDataType("string");
- _.peekOverlay.CheckPrimitiveValue("EDIT");
- _.peekOverlay.ResetHover();
-
- // check if overlay closes
- _.peekOverlay.HoverCode(16, 3, "store");
- _.peekOverlay.IsOverlayOpen();
- _.peekOverlay.ResetHover();
- _.peekOverlay.IsOverlayOpen(false);
-
- // widget object
- _.peekOverlay.HoverCode(17, 1, "Table1");
- _.peekOverlay.IsOverlayOpen();
- _.peekOverlay.VerifyDataType("object");
- _.peekOverlay.ResetHover();
-
- // widget property
- _.peekOverlay.HoverCode(18, 3, "pageNo");
- _.peekOverlay.IsOverlayOpen();
- _.peekOverlay.VerifyDataType("number");
- _.peekOverlay.CheckPrimitiveValue("1");
- _.peekOverlay.ResetHover();
-
- // widget property
- _.peekOverlay.HoverCode(19, 3, "tableData");
- _.peekOverlay.IsOverlayOpen();
- _.peekOverlay.VerifyDataType("array");
- _.peekOverlay.CheckObjectArrayInOverlay([{}, {}, {}]);
- _.peekOverlay.ResetHover();
-
- // basic nested property
- _.peekOverlay.HoverCode(20, 7, "id");
- _.peekOverlay.IsOverlayOpen();
- _.peekOverlay.VerifyDataType("number");
- _.peekOverlay.CheckPrimitiveValue("1");
- _.peekOverlay.ResetHover();
-
- // undefined object
- _.peekOverlay.HoverCode(21, 1, "aljshdlja");
- _.peekOverlay.IsOverlayOpen(false);
- _.peekOverlay.ResetHover();
-
- // this keyword
- _.peekOverlay.HoverCode(22, 3, "numArray");
- _.peekOverlay.IsOverlayOpen();
- _.peekOverlay.VerifyDataType("array");
- _.peekOverlay.CheckPrimitveArrayInOverlay([1, 2, 3]);
- _.peekOverlay.ResetHover();
-
- // pageList is an internal property - peek overlay shouldn't work
- _.peekOverlay.HoverCode(23, 1, "pageList");
- _.peekOverlay.IsOverlayOpen(false);
- _.peekOverlay.ResetHover();
+ _.entityExplorer.DragDropWidgetNVerify("tablewidgetv2", 500, 100);
+ _.entityExplorer.NavigateToSwitcher("Explorer");
+ _.table.AddSampleTableData();
+ _.apiPage.CreateAndFillApi(_.tedTestConfig.mockApiUrl);
+ _.apiPage.RunAPI();
+ _.apiPage.CreateAndFillApi(_.tedTestConfig.mockApiUrl);
+ _.jsEditor.CreateJSObject(JsObjectContent, {
+ paste: true,
+ completeReplace: true,
+ toRun: false,
+ shouldCreateNewJSObj: true,
+ lineNumber: 0,
+ prettify: true,
});
+ _.jsEditor.SelectFunctionDropdown("myFun2");
+ _.jsEditor.RunJSObj();
+ _.agHelper.Sleep();
+ _.debuggerHelper.CloseBottomBar();
+
+ // check number array
+ _.peekOverlay.HoverCode(8, 3, "numArray");
+ _.peekOverlay.IsOverlayOpen();
+ _.peekOverlay.VerifyDataType("array");
+ _.peekOverlay.CheckPrimitveArrayInOverlay([1, 2, 3]);
+ _.peekOverlay.ResetHover();
+
+ // check basic object
+ _.peekOverlay.HoverCode(9, 3, "objectData");
+ _.peekOverlay.IsOverlayOpen();
+ _.peekOverlay.VerifyDataType("object");
+ _.peekOverlay.CheckBasicObjectInOverlay({ x: 123, y: "123" });
+ _.peekOverlay.ResetHover();
+
+ // check null - with this keyword
+ _.peekOverlay.HoverCode(10, 3, "nullData");
+ _.peekOverlay.IsOverlayOpen();
+ _.peekOverlay.VerifyDataType("null");
+ _.peekOverlay.CheckPrimitiveValue("null");
+ _.peekOverlay.ResetHover();
+
+ // check number
+ _.peekOverlay.HoverCode(11, 3, "numberData");
+ _.peekOverlay.IsOverlayOpen();
+ _.peekOverlay.VerifyDataType("number");
+ _.peekOverlay.CheckPrimitiveValue("1");
+ _.peekOverlay.ResetHover();
+
+ // check boolean
+ _.peekOverlay.HoverCode(12, 3, "isLoading");
+ _.peekOverlay.IsOverlayOpen();
+ _.peekOverlay.VerifyDataType("boolean");
+ _.peekOverlay.CheckPrimitiveValue("false");
+ _.peekOverlay.ResetHover();
+
+ // TODO: handle this function failure on CI tests -> "function(){}"
+ // check function
+ // _.peekOverlay.HoverCode(13, 3, "run");
+ // _.peekOverlay.IsOverlayOpen();
+ // _.peekOverlay.VerifyDataType("function");
+ // _.peekOverlay.CheckPrimitiveValue("function () {}");
+ // _.peekOverlay.ResetHover();
+
+ // check undefined
+ _.peekOverlay.HoverCode(14, 3, "data");
+ _.peekOverlay.IsOverlayOpen();
+ _.peekOverlay.VerifyDataType("undefined");
+ _.peekOverlay.CheckPrimitiveValue("undefined");
+ _.peekOverlay.ResetHover();
+
+ // check string
+ _.peekOverlay.HoverCode(15, 3, "mode");
+ _.peekOverlay.IsOverlayOpen();
+ _.peekOverlay.VerifyDataType("string");
+ _.peekOverlay.CheckPrimitiveValue("EDIT");
+ _.peekOverlay.ResetHover();
+
+ // check if overlay closes
+ _.peekOverlay.HoverCode(16, 3, "store");
+ _.peekOverlay.IsOverlayOpen();
+ _.peekOverlay.ResetHover();
+ _.peekOverlay.IsOverlayOpen(false);
+
+ // widget object
+ _.peekOverlay.HoverCode(17, 1, "Table1");
+ _.peekOverlay.IsOverlayOpen();
+ _.peekOverlay.VerifyDataType("object");
+ _.peekOverlay.ResetHover();
+
+ // widget property
+ _.peekOverlay.HoverCode(18, 3, "pageNo");
+ _.peekOverlay.IsOverlayOpen();
+ _.peekOverlay.VerifyDataType("number");
+ _.peekOverlay.CheckPrimitiveValue("1");
+ _.peekOverlay.ResetHover();
+
+ // widget property
+ _.peekOverlay.HoverCode(19, 3, "tableData");
+ _.peekOverlay.IsOverlayOpen();
+ _.peekOverlay.VerifyDataType("array");
+ _.peekOverlay.CheckObjectArrayInOverlay([{}, {}, {}]);
+ _.peekOverlay.ResetHover();
+
+ // basic nested property
+ _.peekOverlay.HoverCode(20, 7, "id");
+ _.peekOverlay.IsOverlayOpen();
+ _.peekOverlay.VerifyDataType("number");
+ _.peekOverlay.CheckPrimitiveValue("1");
+ _.peekOverlay.ResetHover();
+
+ // undefined object
+ _.peekOverlay.HoverCode(21, 1, "aljshdlja");
+ _.peekOverlay.IsOverlayOpen(false);
+ _.peekOverlay.ResetHover();
+
+ // this keyword
+ _.peekOverlay.HoverCode(22, 3, "numArray");
+ _.peekOverlay.IsOverlayOpen();
+ _.peekOverlay.VerifyDataType("array");
+ _.peekOverlay.CheckPrimitveArrayInOverlay([1, 2, 3]);
+ _.peekOverlay.ResetHover();
+
+ // pageList is an internal property - peek overlay shouldn't work
+ _.peekOverlay.HoverCode(23, 1, "pageList");
+ _.peekOverlay.IsOverlayOpen(false);
+ _.peekOverlay.ResetHover();
});
});
@@ -141,16 +139,16 @@ const JsObjectContent = `export default {
myFun1: () => {
// TODO: handle this keyword failure on CI tests
JSObject1.numArray;
- JSObject1.objectData;
- JSObject1.nullData;
+ JSObject1.objectData;
+ JSObject1.nullData;
JSObject1.numberData;
- Api1.isLoading;
- Api1.run();
+ Api1.isLoading;
+ Api1.run();
Api2.data;
- appsmith.mode;
+ appsmith.mode;
appsmith.store.abc;
Table1;
- Table1.pageNo;
+ Table1.pageNo;
Table1.tableData;
Api1.data[0].id;
aljshdlja;
diff --git a/app/client/cypress/e2e/Regression/ClientSide/PublishedApps/PublishedModeToastToggle_Spec.ts b/app/client/cypress/e2e/Regression/ClientSide/PublishedApps/PublishedModeToastToggle_Spec.ts
index 4255a35807..97bc8e8a98 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/PublishedApps/PublishedModeToastToggle_Spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/PublishedApps/PublishedModeToastToggle_Spec.ts
@@ -15,19 +15,15 @@ describe("Published mode toggle toast with debug flag in the url", function () {
});
it("1. Should not show any application related toasts", function () {
- cy.fixture("datasources").then((datasourceFormData) => {
- _.apiPage.CreateAndFillApi(
- datasourceFormData["mockApiUrl"],
- "Correct_users",
- );
- _.apiPage.ToggleOnPageLoadRun(true);
- _.apiPage.CreateAndFillApi(
- datasourceFormData["mockApiUrl"].replace("mock-api", "mock-api2err"),
- "Incorrect_users",
- );
- _.apiPage.ToggleOnPageLoadRun(true);
- _.jsEditor.CreateJSObject(
- `export default {
+ _.apiPage.CreateAndFillApi(_.tedTestConfig.mockApiUrl, "Correct_users");
+ _.apiPage.ToggleOnPageLoadRun(true);
+ _.apiPage.CreateAndFillApi(
+ _.tedTestConfig.mockApiUrl.replace("mock-api", "mock-api2err"),
+ "Incorrect_users",
+ );
+ _.apiPage.ToggleOnPageLoadRun(true);
+ _.jsEditor.CreateJSObject(
+ `export default {
async myFun1 () {
const res = await Correct_users.run();
showAlert("Hello info", "info");
@@ -38,35 +34,34 @@ describe("Published mode toggle toast with debug flag in the url", function () {
return res;
}
}`,
- {
- paste: true,
- completeReplace: true,
- toRun: false,
- shouldCreateNewJSObj: true,
- },
- );
- _.deployMode.DeployApp(undefined, true, true, false);
+ {
+ paste: true,
+ completeReplace: true,
+ toRun: false,
+ shouldCreateNewJSObj: true,
+ },
+ );
+ _.deployMode.DeployApp(undefined, true, true, false);
- _.agHelper.AssertElementAbsence(_.locators._toastMsg);
+ _.agHelper.AssertElementAbsence(_.locators._toastMsg);
- _.agHelper.ClickButton(SHOW_ALERT_WORKING_BUTTON);
- _.agHelper.AssertContains(SHOW_ALERT_MSG, "exist", _.locators._toastMsg);
+ _.agHelper.ClickButton(SHOW_ALERT_WORKING_BUTTON);
+ _.agHelper.AssertContains(SHOW_ALERT_MSG, "exist", _.locators._toastMsg);
- _.agHelper.ClickButton(SHOW_ALERT_NOT_WORKING_BUTTON);
- _.agHelper.AssertContains(
- SHOW_ALERT_NOT_WORKING_MSG,
- "not.exist",
- _.locators._toastMsg,
- );
+ _.agHelper.ClickButton(SHOW_ALERT_NOT_WORKING_BUTTON);
+ _.agHelper.AssertContains(
+ SHOW_ALERT_NOT_WORKING_MSG,
+ "not.exist",
+ _.locators._toastMsg,
+ );
- _.agHelper.ClickButton(RUN_JS_OBJECT_BUTTON);
- _.agHelper.AssertContains("Hello success", "exist", _.locators._toastMsg);
- _.agHelper.AssertContains(
- RUN_JS_OBJECT_MSG,
- "not.exist",
- _.locators._toastMsg,
- );
- });
+ _.agHelper.ClickButton(RUN_JS_OBJECT_BUTTON);
+ _.agHelper.AssertContains("Hello success", "exist", _.locators._toastMsg);
+ _.agHelper.AssertContains(
+ RUN_JS_OBJECT_MSG,
+ "not.exist",
+ _.locators._toastMsg,
+ );
});
it("2. Should show all application related toasts with debug flag true in url", function () {
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Refactoring/Refactoring_spec.ts b/app/client/cypress/e2e/Regression/ClientSide/Refactoring/Refactoring_spec.ts
index 6f7ae8d222..79f598de34 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Refactoring/Refactoring_spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/Refactoring/Refactoring_spec.ts
@@ -7,6 +7,7 @@ import {
jsEditor,
locators,
propPane,
+ tedTestConfig,
} from "../../../../support/Objects/ObjectsCore";
describe("Validate JS Object Refactoring does not affect the comments & variables", () => {
@@ -40,10 +41,8 @@ describe("Validate JS Object Refactoring does not affect the comments & variable
dataSources.CreateDataSource("MySql", true, false);
cy.get("@dsName").then(($dsName) => {
dsName = $dsName;
- });
- //Selecting paintings table from MySQL DS
- cy.fixture("datasources").then((datasourceFormData: any) => {
+ //Selecting paintings table from MySQL DS
//Initialize new JSObject with custom code
jsEditor.CreateJSObject(jsCode);
//Initialize new Query entity with custom query
@@ -54,7 +53,7 @@ describe("Validate JS Object Refactoring does not affect the comments & variable
); //Creating query from EE overlay
//Initialize new API entity with custom header
apiPage.CreateAndFillApi(
- datasourceFormData["mockApiUrl"],
+ tedTestConfig.mockApiUrl,
refactorInput.api.oldName,
);
apiPage.EnterHeader("key1", `{{\tJSObject1.myVar1}}`);
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Widgets/Datepicker/DatePickerV2_spec.js b/app/client/cypress/e2e/Regression/ClientSide/Widgets/Datepicker/DatePickerV2_spec.js
index d4d10701db..59b25ce6a1 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Widgets/Datepicker/DatePickerV2_spec.js
+++ b/app/client/cypress/e2e/Regression/ClientSide/Widgets/Datepicker/DatePickerV2_spec.js
@@ -129,14 +129,12 @@ describe("DatePicker Widget Property pane tests with js bindings", function () {
.type("04/05/2021 06:25")
.wait(2000);
cy.selectDateFormat("LLL");
- cy.wait("@updateLayout");
cy.get(".t--draggable-textwidget .bp3-ui-text")
.first()
.should("contain.text", "May 4, 2021 6:25 AM");
- _.propPane.EnterJSContext("Default Date", "2020-02-01");
- _.propPane.EnterJSContext("Min Date", "2020-01-01");
- _.propPane.EnterJSContext("Max Date", "2020-02-10");
+ _.propPane.UpdatePropertyFieldValue("Default Date", "2020-02-01");
+ _.propPane.UpdatePropertyFieldValue("Max Date", "2020-02-10");
_.agHelper.AssertErrorTooltip("Date out of range");
});
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Widgets/Filepicker/FilePickerV2_spec.js b/app/client/cypress/e2e/Regression/ClientSide/Widgets/Filepicker/FilePickerV2_spec.js
index 9ff65ba536..447391d5b8 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Widgets/Filepicker/FilePickerV2_spec.js
+++ b/app/client/cypress/e2e/Regression/ClientSide/Widgets/Filepicker/FilePickerV2_spec.js
@@ -34,32 +34,30 @@ describe("File picker widget v2", () => {
});
it("3. Check if the uploaded data does not reset when back from query page", () => {
- cy.fixture("datasources").then((datasourceFormData) => {
- cy.openPropertyPane("textwidget");
- cy.updateCodeInput(
- ".t--property-control-text",
- `{{FilePicker1.files[0].name}}`,
- );
- cy.createAndFillApi(datasourceFormData["mockApiUrl"], "");
- cy.updateCodeInput(
- "[class*='t--actionConfiguration']",
- "{{FilePicker1.files}}",
- );
- cy.wait(1000);
- cy.validateEvaluatedValue("testFile.mov");
+ cy.openPropertyPane("textwidget");
+ cy.updateCodeInput(
+ ".t--property-control-text",
+ `{{FilePicker1.files[0].name}}`,
+ );
+ cy.createAndFillApi(_.tedTestConfig.mockApiUrl, "");
+ cy.updateCodeInput(
+ "[class*='t--actionConfiguration']",
+ "{{FilePicker1.files}}",
+ );
+ cy.wait(1000);
+ cy.validateEvaluatedValue("testFile.mov");
- cy.get("[data-testid='more-action-trigger']")
- .first()
- .click({ force: true });
+ cy.get("[data-testid='more-action-trigger']")
+ .first()
+ .click({ force: true });
- // Go back to widgets page
- _.entityExplorer.NavigateToSwitcher("Widgets", 0, true);
- cy.get(widgetsPage.filepickerwidgetv2).should(
- "contain",
- "1 files selected",
- );
- cy.get(".t--widget-textwidget").should("contain", "testFile.mov");
- });
+ // Go back to widgets page
+ _.entityExplorer.NavigateToSwitcher("Widgets", 0, true);
+ cy.get(widgetsPage.filepickerwidgetv2).should(
+ "contain",
+ "1 files selected",
+ );
+ cy.get(".t--widget-textwidget").should("contain", "testFile.mov");
});
it("4. Check if the uploaded file is removed on click of cancel button", () => {
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Widgets/List/List6_spec.js b/app/client/cypress/e2e/Regression/ClientSide/Widgets/List/List6_spec.js
index 48fc0f2efe..e837b833be 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Widgets/List/List6_spec.js
+++ b/app/client/cypress/e2e/Regression/ClientSide/Widgets/List/List6_spec.js
@@ -36,11 +36,6 @@ describe("Binding the list widget with text widget", function () {
"Items",
'[[{ "name": "pawan"}, { "name": "Vivek" }], [{ "name": "Ashok"}, {"name": "rahul"}]]',
);
- cy.wait("@updateLayout").should(
- "have.nested.property",
- "response.body.responseMeta.status",
- 200,
- );
_.entityExplorer.ExpandCollapseEntity("List1");
_.entityExplorer.ExpandCollapseEntity("Container1");
_.entityExplorer.SelectEntityByName("Text3");
@@ -50,11 +45,6 @@ describe("Binding the list widget with text widget", function () {
"Text",
'{{currentItem.map(item => item.name).join(", ")}}',
);
- cy.wait("@updateLayout").should(
- "have.nested.property",
- "response.body.responseMeta.status",
- 200,
- );
_.deployMode.DeployApp();
cy.wait(2000);
cy.get(".t--widget-textwidget span:contains('pawan, Vivek')").should(
@@ -76,23 +66,12 @@ describe("Binding the list widget with text widget", function () {
"Items",
'[{ "name": "pawan"}, { "name": "Vivek" }]',
);
- cy.wait("@updateLayout").should(
- "have.nested.property",
- "response.body.responseMeta.status",
- 200,
- );
-
_.entityExplorer.ExpandCollapseEntity("List1");
_.entityExplorer.ExpandCollapseEntity("Container1");
_.entityExplorer.SelectEntityByName("Text3");
cy.wait(1000);
_.propPane.UpdatePropertyFieldValue("Text", "{{currentItem.name}}");
- cy.wait("@updateLayout").should(
- "have.nested.property",
- "response.body.responseMeta.status",
- 200,
- );
_.deployMode.DeployApp();
cy.wait(2000);
cy.get(".t--widget-textwidget span:contains('Vivek')").should(
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Widgets/ListV2/Listv2_dataIdentifierProperty_spec.js b/app/client/cypress/e2e/Regression/ClientSide/Widgets/ListV2/Listv2_dataIdentifierProperty_spec.js
index 00e63fe6ef..1545148e9a 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Widgets/ListV2/Listv2_dataIdentifierProperty_spec.js
+++ b/app/client/cypress/e2e/Regression/ClientSide/Widgets/ListV2/Listv2_dataIdentifierProperty_spec.js
@@ -1,24 +1,17 @@
-const simpleListDSL = require("../../../../../fixtures/Listv2/simpleList.json");
-const simpleListWithLargeDataDSL = require("../../../../../fixtures/Listv2/simpleListWithLargeData.json");
-const ListV2WithNullPrimaryKeyDSL = require("../../../../../fixtures/Listv2/ListV2WithNullPrimaryKey.json");
const widgetsPage = require("../../../../../locators/Widgets.json");
const commonlocators = require("../../../../../locators/commonlocators.json");
import * as _ from "../../../../../support/Objects/ObjectsCore";
const propertyControl = ".t--property-control";
-
const widgetSelector = (name) => `[data-widgetname-cy="${name}"]`;
-
function testJsontextClear(endp) {
const modifierKey = Cypress.platform === "darwin" ? "meta" : "ctrl";
-
cy.get(".t--property-control-" + endp + " .CodeMirror textarea")
.first()
.focus({ force: true })
.type(`{${modifierKey}}{a}`, { force: true })
.type(`{${modifierKey}}{del}`, { force: true });
}
-
const data = [
{
id: "001",
@@ -50,7 +43,7 @@ describe("List v2 - Data Identifier property", () => {
});
it("1. is present in the property pane", () => {
- cy.addDsl(simpleListDSL);
+ _.agHelper.AddDsl("Listv2/simpleList");
cy.openPropertyPane("listwidgetv2");
@@ -132,7 +125,7 @@ describe("List v2 - Data Identifier property", () => {
});
it("6. with large data set and data identifier set, the rows should render", () => {
- cy.addDsl(simpleListWithLargeDataDSL);
+ _.agHelper.AddDsl("Listv2/simpleListWithLargeData");
cy.openPropertyPane("listwidgetv2");
@@ -180,7 +173,8 @@ describe("List v2 - Data Identifier property", () => {
});
it("9. Widgets get displayed when PrimaryKey doesn't exist - SSP", () => {
- cy.addDsl(ListV2WithNullPrimaryKeyDSL);
+ _.agHelper.AddDsl("Listv2/ListV2WithNullPrimaryKey");
+ _.agHelper.AddDsl("Listv2/ListV2WithNullPrimaryKey");
cy.createAndFillApi(
"https://api.punkapi.com/v2/beers?page={{List1.pageNo}}&per_page={{List1.pageSize}}",
"",
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Widgets/ListV2/Listv2_defaultSelectedItem_spec.js b/app/client/cypress/e2e/Regression/ClientSide/Widgets/ListV2/Listv2_defaultSelectedItem_spec.js
index 5dfa06b7c6..a33cd73d75 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Widgets/ListV2/Listv2_defaultSelectedItem_spec.js
+++ b/app/client/cypress/e2e/Regression/ClientSide/Widgets/ListV2/Listv2_defaultSelectedItem_spec.js
@@ -3,11 +3,8 @@ const commonlocators = require("../../../../../locators/commonlocators.json");
import * as _ from "../../../../../support/Objects/ObjectsCore";
const widgetSelector = (name) => `[data-widgetname-cy="${name}"]`;
-
const items = dsl.dsl.children[4]?.listData;
-
const containerWidgetSelector = `[type="CONTAINER_WIDGET"]`;
-
function testJsontextClear(endp) {
const modifierKey = Cypress.platform === "darwin" ? "meta" : "ctrl";
@@ -47,9 +44,7 @@ const verifyDefaultItem = () => {
};
function setUpDataSource() {
- cy.fixture("datasources").then((datasourceFormData) => {
- _.apiPage.CreateAndFillApi(datasourceFormData["mockApiUrl"] + "0");
- });
+ _.apiPage.CreateAndFillApi(_.tedTestConfig.mockApiUrl + "0");
cy.RunAPI();
_.entityExplorer.SelectEntityByName("List1");
cy.wait(200);
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Widgets/ListV2/Listv2_onItemClick_spec.js b/app/client/cypress/e2e/Regression/ClientSide/Widgets/ListV2/Listv2_onItemClick_spec.js
index 102b1a49dd..f41cca7ec3 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Widgets/ListV2/Listv2_onItemClick_spec.js
+++ b/app/client/cypress/e2e/Regression/ClientSide/Widgets/ListV2/Listv2_onItemClick_spec.js
@@ -1,6 +1,7 @@
const commonlocators = require("../../../../../locators/commonlocators.json");
const widgetsPage = require("../../../../../locators/Widgets.json");
import {
+ agHelper,
draggableWidgets,
entityExplorer,
} from "../../../../../support/Objects/ObjectsCore";
@@ -28,11 +29,6 @@ function deleteAllWidgetsInContainer() {
cy.wait(1000);
}
-function validateToastExist() {
- cy.validateToastMessage("ListWidget_Blue_0");
- cy.wait(1000);
-}
-
function validateToastDoestExist() {
cy.wait(500);
cy.get(commonlocators.toastmsg, { timeout: 100 }).should("not.exist");
@@ -57,35 +53,27 @@ describe("List widget v2 onItemClick", () => {
.first()
.click({ force: true });
- cy.validateToastMessage("ListWidget_Blue_0");
- cy.waitUntil(() =>
- cy.get(commonlocators.toastmsg).should("not.be.visible"),
- );
+ agHelper.WaitUntilToastDisappear("ListWidget_Blue_0");
+
cy.get(`${widgetSelector("List1")} ${containerWidgetSelector}`)
.eq(1)
.click({ force: true });
- cy.validateToastMessage("ListWidget_Green_1");
- cy.waitUntil(() =>
- cy.get(commonlocators.toastmsg).should("not.be.visible"),
- );
+ agHelper.WaitUntilToastDisappear("ListWidget_Green_1");
cy.get(`${widgetSelector("List1")} ${containerWidgetSelector}`)
.eq(2)
.click({ force: true });
- cy.validateToastMessage("ListWidget_Red_2");
- cy.waitUntil(() =>
- cy.get(commonlocators.toastmsg).should("not.be.visible"),
- );
+ agHelper.WaitUntilToastDisappear("ListWidget_Red_2");
});
it("2. List widget V2 with onItemClick should be triggered when child widget without event is clicked", () => {
cy.get(widgetSelector("Image1")).first().click({ force: true });
- validateToastExist();
+ agHelper.WaitUntilToastDisappear("ListWidget_Blue_0");
cy.get(widgetSelector("Text1")).first().click({ force: true });
- validateToastExist();
+ agHelper.WaitUntilToastDisappear("ListWidget_Blue_0");
deleteAllWidgetsInContainer();
@@ -127,8 +115,7 @@ describe("List widget v2 onItemClick", () => {
cy.get(`${widgetSelector("Button1")} button`)
.first()
.click({ force: true });
- validateToastExist();
- cy.get(commonlocators.toastBody).first().click();
+ agHelper.WaitUntilToastDisappear("ListWidget_Blue_0");
cy.get(widgetsPage.toggleOnClick).click({ force: true });
cy.get(".t--property-control-onclick").then(($el) => {
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Widgets/Multiselect/MultiSelect2_spec.js b/app/client/cypress/e2e/Regression/ClientSide/Widgets/Multiselect/MultiSelect2_spec.js
index 933400417d..2f6226cecf 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Widgets/Multiselect/MultiSelect2_spec.js
+++ b/app/client/cypress/e2e/Regression/ClientSide/Widgets/Multiselect/MultiSelect2_spec.js
@@ -231,7 +231,7 @@ describe("MultiSelect Widget Functionality", function () {
},
];
- it("8. Verify MultiSelect resets to default value", function () {
+ it("6. Verify MultiSelect resets to default value", function () {
resetTestCases.forEach((testCase) => {
const { defaultValue, options, optionsToDeselect, optionsToSelect } =
testCase;
@@ -244,6 +244,8 @@ describe("MultiSelect Widget Functionality", function () {
_.propPane.UpdatePropertyFieldValue(
"Default selected values",
JSON.stringify(defaultValue, null, 2),
+ true,
+ false,
);
// select other options
_.agHelper.SelectFromMultiSelect(optionsToSelect);
@@ -264,7 +266,7 @@ describe("MultiSelect Widget Functionality", function () {
});
});
- it("9. Verify MultiSelect deselection behavior", function () {
+ it("7. Verify MultiSelect deselection behavior", function () {
cy.openPropertyPane("multiselectwidgetv2");
// set options
_.propPane.UpdatePropertyFieldValue(
@@ -278,16 +280,14 @@ describe("MultiSelect Widget Functionality", function () {
cy.get(getWidgetSelector("textwidget")).eq(1).should("have.text", "");
});
- it("10. Dropdown Functionality To Unchecked Visible Widget", function () {
+ it("8. Dropdown Functionality To Unchecked Visible Widget", function () {
cy.togglebarDisable(commonlocators.visibleCheckbox);
_.deployMode.DeployApp();
cy.get(publish.multiselectwidgetv2 + " " + ".rc-select-selector").should(
"not.exist",
);
_.deployMode.NavigateBacktoEditor();
- });
-
- it("11. Dropdown Functionality To Check Visible Widget", function () {
+ // Dropdown Functionality To Check Visible Widget", function () {
cy.openPropertyPane("multiselectwidgetv2");
cy.togglebar(commonlocators.visibleCheckbox);
_.deployMode.DeployApp();
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Widgets/Sliders/NumberSlider_spec.ts b/app/client/cypress/e2e/Regression/ClientSide/Widgets/Sliders/NumberSlider_spec.ts
index 004f54cbb4..aa5ee19f0e 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Widgets/Sliders/NumberSlider_spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/Widgets/Sliders/NumberSlider_spec.ts
@@ -107,7 +107,7 @@ describe("Number Slider spec", () => {
_.entityExplorer.SelectEntityByName("NumberSlider1", "Widgets");
// Change the Step size to 10
- _.propPane.UpdatePropertyFieldValue("Step size", "10");
+ _.propPane.UpdatePropertyFieldValue("Step size", "10", true, false);
// Change the slider value
_.agHelper
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Widgets/Sliders/RangeSlider_spec.ts b/app/client/cypress/e2e/Regression/ClientSide/Widgets/Sliders/RangeSlider_spec.ts
index 61c1eee91e..0b81ea842e 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Widgets/Sliders/RangeSlider_spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/Widgets/Sliders/RangeSlider_spec.ts
@@ -145,8 +145,8 @@ describe("Range Slider spec", () => {
});
// Change the Step size to 10
- _.propPane.UpdatePropertyFieldValue("Min. range", "10");
- _.propPane.UpdatePropertyFieldValue("Step size", "10");
+ _.propPane.UpdatePropertyFieldValue("Min. range", "10", true, false);
+ _.propPane.UpdatePropertyFieldValue("Step size", "10", true, false);
_.agHelper
.GetElement(_.locators._sliderThumb)
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Widgets/TableV2/TableV2_DisplayText_spec.ts b/app/client/cypress/e2e/Regression/ClientSide/Widgets/TableV2/TableV2_DisplayText_spec.ts
index 908a964e19..59195265ce 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Widgets/TableV2/TableV2_DisplayText_spec.ts
+++ b/app/client/cypress/e2e/Regression/ClientSide/Widgets/TableV2/TableV2_DisplayText_spec.ts
@@ -62,6 +62,8 @@ describe("Table V2 sort & filter using display text functionality", () => {
propPane.UpdatePropertyFieldValue(
"Display text",
"{{['X','Y','Z'][currentIndex]}}",
+ true,
+ false,
);
agHelper.RemoveEvaluatedPopUp();
table.OpenNFilterTable("name", "contains", "Y");
@@ -87,6 +89,8 @@ describe("Table V2 sort & filter using display text functionality", () => {
propPane.UpdatePropertyFieldValue(
"Display text",
"{{['X','Y','Z'][currentIndex]}}",
+ true,
+ false,
);
table.SortColumn("name", "ascending");
table.ReadTableRowColumnData(0, 0, "v2").then((data) => {
diff --git a/app/client/cypress/e2e/Regression/ClientSide/Widgets/TableV2/TableV2_Widget_Add_button_spec.js b/app/client/cypress/e2e/Regression/ClientSide/Widgets/TableV2/TableV2_Widget_Add_button_spec.js
index 73bcb6bfea..2d41c5de7b 100644
--- a/app/client/cypress/e2e/Regression/ClientSide/Widgets/TableV2/TableV2_Widget_Add_button_spec.js
+++ b/app/client/cypress/e2e/Regression/ClientSide/Widgets/TableV2/TableV2_Widget_Add_button_spec.js
@@ -32,8 +32,6 @@ describe("Table Widget V2 property pane feature validation", function () {
agHelper.AssertAutoSave();
// Validating the button action by clicking
cy.get(widgetsPage.tableV2Btn).last().click({ force: true });
- // eslint-disable-next-line cypress/no-unnecessary-waiting
- cy.wait(3000);
// Validating the toast message
agHelper.WaitUntilToastDisappear("Successful tobias.funke@reqres.in");
diff --git a/app/client/cypress/e2e/Regression/ServerSide/ApiTests/API_EvaluatedValue_spec.ts b/app/client/cypress/e2e/Regression/ServerSide/ApiTests/API_EvaluatedValue_spec.ts
index 2b1e480e27..22f913c0fb 100644
--- a/app/client/cypress/e2e/Regression/ServerSide/ApiTests/API_EvaluatedValue_spec.ts
+++ b/app/client/cypress/e2e/Regression/ServerSide/ApiTests/API_EvaluatedValue_spec.ts
@@ -1,4 +1,7 @@
-import { apiPage, hostPort } from "../../../../support/Objects/ObjectsCore";
+import {
+ apiPage,
+ tedTestConfig,
+} from "../../../../support/Objects/ObjectsCore";
describe("Validate API URL Evaluated value", () => {
it("1. Check if url object does not crash App", () => {
@@ -10,8 +13,8 @@ describe("Validate API URL Evaluated value", () => {
it("2. Check if path field strings have not been JSON.stringified - #24696", () => {
apiPage.CreateApi("SecondAPI");
apiPage.EnterURL(
- hostPort.mockApiUrl + `/{{SecondAPI.isLoading}}`,
- hostPort.mockApiUrl + `/false`,
+ tedTestConfig.mockApiUrl + `/{{SecondAPI.isLoading}}`,
+ tedTestConfig.mockApiUrl + `/false`,
);
});
});
diff --git a/app/client/cypress/e2e/Regression/ServerSide/ApiTests/API_TestExecuteWithDynamicBindingInUrl_spec.ts b/app/client/cypress/e2e/Regression/ServerSide/ApiTests/API_TestExecuteWithDynamicBindingInUrl_spec.ts
index 0b8205cc9a..d97bb30fa4 100644
--- a/app/client/cypress/e2e/Regression/ServerSide/ApiTests/API_TestExecuteWithDynamicBindingInUrl_spec.ts
+++ b/app/client/cypress/e2e/Regression/ServerSide/ApiTests/API_TestExecuteWithDynamicBindingInUrl_spec.ts
@@ -1,10 +1,9 @@
-import datasourceFormData from "../../../../fixtures/datasources.json";
-
import {
apiPage,
agHelper,
jsEditor,
entityItems,
+ tedTestConfig,
} from "../../../../support/Objects/ObjectsCore";
describe("Test API execution with dynamic binding in URL - Bug #24218", () => {
@@ -15,7 +14,7 @@ describe("Test API execution with dynamic binding in URL - Bug #24218", () => {
myVar1: [],
myVar2: {},
myFun1 () {
- storeValue("api_url", "${datasourceFormData["mockApiUrl"]}");
+ storeValue("api_url", "${tedTestConfig.mockApiUrl}");
},
myFun2: async function() {
}
diff --git a/app/client/cypress/e2e/Regression/ServerSide/ApiTests/CurlImportFlow_spec.js b/app/client/cypress/e2e/Regression/ServerSide/ApiTests/CurlImportFlow_spec.js
index 2cfc1461f4..7485b6864b 100644
--- a/app/client/cypress/e2e/Regression/ServerSide/ApiTests/CurlImportFlow_spec.js
+++ b/app/client/cypress/e2e/Regression/ServerSide/ApiTests/CurlImportFlow_spec.js
@@ -7,34 +7,31 @@ import {
apiPage,
dataSources,
entityItems,
+ tedTestConfig,
} from "../../../../support/Objects/ObjectsCore";
describe("Test curl import flow", function () {
it("1. Test curl import flow Run and Delete", function () {
- cy.fixture("datasources").then((datasourceFormData) => {
- localStorage.setItem("ApiPaneV2", "ApiPaneV2");
- cy.NavigateToApiEditor();
- dataSources.NavigateToDSCreateNew();
- cy.get(ApiEditor.curlImage).click({ force: true });
- cy.get("textarea").type(
- "curl -X GET " + datasourceFormData["mockApiUrl"],
- );
- cy.importCurl();
- cy.get("@curlImport").then((response) => {
- expect(response.response.body.responseMeta.success).to.eq(true);
- cy.get(apiwidget.ApiName)
- .invoke("text")
- .then((text) => {
- const someText = text;
- expect(someText).to.equal(response.response.body.data.name);
- });
- });
- cy.RunAPI();
- cy.ResponseStatusCheck("200 OK");
- agHelper.ActionContextMenuWithInPane({
- action: "Delete",
- entityType: entityItems.Api,
- });
+ localStorage.setItem("ApiPaneV2", "ApiPaneV2");
+ cy.NavigateToApiEditor();
+ dataSources.NavigateToDSCreateNew();
+ cy.get(ApiEditor.curlImage).click({ force: true });
+ cy.get("textarea").type("curl -X GET " + tedTestConfig.mockApiUrl);
+ cy.importCurl();
+ cy.get("@curlImport").then((response) => {
+ expect(response.response.body.responseMeta.success).to.eq(true);
+ cy.get(apiwidget.ApiName)
+ .invoke("text")
+ .then((text) => {
+ const someText = text;
+ expect(someText).to.equal(response.response.body.data.name);
+ });
+ });
+ cy.RunAPI();
+ cy.ResponseStatusCheck("200 OK");
+ agHelper.ActionContextMenuWithInPane({
+ action: "Delete",
+ entityType: entityItems.Api,
});
});
diff --git a/app/client/cypress/e2e/Regression/ServerSide/JsFunctionExecution/PlatformFn_spec.ts b/app/client/cypress/e2e/Regression/ServerSide/JsFunctionExecution/PlatformFn_spec.ts
index aacfae76ea..6561ce1acf 100644
--- a/app/client/cypress/e2e/Regression/ServerSide/JsFunctionExecution/PlatformFn_spec.ts
+++ b/app/client/cypress/e2e/Regression/ServerSide/JsFunctionExecution/PlatformFn_spec.ts
@@ -1,16 +1,17 @@
+import { data } from "cypress/types/jquery";
import {
agHelper,
apiPage,
jsEditor,
debuggerHelper,
+ tedTestConfig,
} from "../../../../support/Objects/ObjectsCore";
describe("Tests functionality of platform function", () => {
it("1. Tests access to outer variable", () => {
- cy.fixture("datasources").then((datasourceFormData: any) => {
- apiPage.CreateAndFillApi(datasourceFormData["mockApiUrl"], "getAllUsers");
- jsEditor.CreateJSObject(
- `export default {
+ apiPage.CreateAndFillApi(tedTestConfig.mockApiUrl, "getAllUsers");
+ jsEditor.CreateJSObject(
+ `export default {
myFun1: () => {
},
@@ -67,83 +68,80 @@ describe("Tests functionality of platform function", () => {
showAlert("Hello").then(() => getAllUsers.run(() => showAlert("World")));
}
}`,
- {
- paste: true,
- completeReplace: true,
- toRun: false,
- shouldCreateNewJSObj: true,
- prettify: false,
- },
- );
- agHelper.Sleep(4000);
- cy.url().then((url) => {
- cy.visit(url, {
- onBeforeLoad: (win) => {
- const latitude = 48.71597183246423;
- const longitude = 21.255670821215418;
- cy.stub(
- win.navigator.geolocation,
- "getCurrentPosition",
- ).callsArgWith(0, {
+ {
+ paste: true,
+ completeReplace: true,
+ toRun: false,
+ shouldCreateNewJSObj: true,
+ prettify: false,
+ },
+ );
+ agHelper.Sleep(4000);
+ cy.url().then((url) => {
+ cy.visit(url, {
+ onBeforeLoad: (win) => {
+ const latitude = 48.71597183246423;
+ const longitude = 21.255670821215418;
+ cy.stub(win.navigator.geolocation, "getCurrentPosition").callsArgWith(
+ 0,
+ {
coords: { latitude, longitude },
- });
- },
- });
-
- jsEditor.SelectFunctionDropdown("accessOuterVariableInsideGeoCb");
- jsEditor.RunJSObj();
- agHelper.AssertContains("Hello World from current position", "exist");
-
- jsEditor.SelectFunctionDropdown("accessOuterVariableInsideSuccessCb");
- jsEditor.RunJSObj();
- agHelper.AssertContains("Hello World from success callback", "exist");
- jsEditor.SelectFunctionDropdown(
- "accessOuterVariableInsideSetIntervalCb",
- );
- jsEditor.RunJSObj();
- agHelper.AssertContains("Hello World from setInterval", "exist");
- jsEditor.SelectFunctionDropdown("accessSetIntervalFromSetTimeout");
- jsEditor.RunJSObj();
- agHelper.AssertContains(
- "Hello World from setInterval inside setTimeout",
- "exist",
- );
- jsEditor.SelectFunctionDropdown("executeTriggersOutsideReqResCycle");
- jsEditor.RunJSObj();
- agHelper.AssertContains("Hello", "exist");
- agHelper.AssertContains("World", "exist");
-
- // Test for meta data
- jsEditor.SelectFunctionDropdown("metaDataForSetTimeout");
- jsEditor.RunJSObj();
- agHelper.GetNClick(jsEditor._logsTab);
- jsEditor.SelectFunctionDropdown("switchMetaData");
- jsEditor.RunJSObj();
- agHelper.Sleep(4000);
- agHelper.GetNClick(jsEditor._logsTab);
- debuggerHelper.DebuggerLogsFilter("JSObject1.metaDataForSetTimeout");
- debuggerHelper.DoesConsoleLogExist("Hello from setTimeout");
-
- jsEditor.SelectFunctionDropdown("metaDataForSetInterval");
- jsEditor.RunJSObj();
- agHelper.GetNClick(jsEditor._logsTab);
- jsEditor.SelectFunctionDropdown("switchMetaData");
- jsEditor.RunJSObj();
- agHelper.Sleep(3000);
- agHelper.GetNClick(jsEditor._logsTab);
- debuggerHelper.DebuggerLogsFilter("JSObject1.metaDataForSetInterval");
- debuggerHelper.DoesConsoleLogExist("Hello from setInterval");
-
- jsEditor.SelectFunctionDropdown("metaDataApiTest");
- jsEditor.RunJSObj();
- agHelper.GetNClick(jsEditor._logsTab);
- jsEditor.SelectFunctionDropdown("switchMetaData");
- jsEditor.RunJSObj();
- agHelper.Sleep(2000);
- agHelper.GetNClick(jsEditor._logsTab);
- debuggerHelper.DebuggerLogsFilter("JSObject1.metaDataApiTest");
- debuggerHelper.DoesConsoleLogExist("Hello from setTimeout inside API");
+ },
+ );
+ },
});
+
+ jsEditor.SelectFunctionDropdown("accessOuterVariableInsideGeoCb");
+ jsEditor.RunJSObj();
+ agHelper.AssertContains("Hello World from current position", "exist");
+
+ jsEditor.SelectFunctionDropdown("accessOuterVariableInsideSuccessCb");
+ jsEditor.RunJSObj();
+ agHelper.AssertContains("Hello World from success callback", "exist");
+ jsEditor.SelectFunctionDropdown("accessOuterVariableInsideSetIntervalCb");
+ jsEditor.RunJSObj();
+ agHelper.AssertContains("Hello World from setInterval", "exist");
+ jsEditor.SelectFunctionDropdown("accessSetIntervalFromSetTimeout");
+ jsEditor.RunJSObj();
+ agHelper.AssertContains(
+ "Hello World from setInterval inside setTimeout",
+ "exist",
+ );
+ jsEditor.SelectFunctionDropdown("executeTriggersOutsideReqResCycle");
+ jsEditor.RunJSObj();
+ agHelper.AssertContains("Hello", "exist");
+ agHelper.AssertContains("World", "exist");
+
+ // Test for meta data
+ jsEditor.SelectFunctionDropdown("metaDataForSetTimeout");
+ jsEditor.RunJSObj();
+ agHelper.GetNClick(jsEditor._logsTab);
+ jsEditor.SelectFunctionDropdown("switchMetaData");
+ jsEditor.RunJSObj();
+ agHelper.Sleep(4000);
+ agHelper.GetNClick(jsEditor._logsTab);
+ debuggerHelper.DebuggerLogsFilter("JSObject1.metaDataForSetTimeout");
+ debuggerHelper.DoesConsoleLogExist("Hello from setTimeout");
+
+ jsEditor.SelectFunctionDropdown("metaDataForSetInterval");
+ jsEditor.RunJSObj();
+ agHelper.GetNClick(jsEditor._logsTab);
+ jsEditor.SelectFunctionDropdown("switchMetaData");
+ jsEditor.RunJSObj();
+ agHelper.Sleep(3000);
+ agHelper.GetNClick(jsEditor._logsTab);
+ debuggerHelper.DebuggerLogsFilter("JSObject1.metaDataForSetInterval");
+ debuggerHelper.DoesConsoleLogExist("Hello from setInterval");
+
+ jsEditor.SelectFunctionDropdown("metaDataApiTest");
+ jsEditor.RunJSObj();
+ agHelper.GetNClick(jsEditor._logsTab);
+ jsEditor.SelectFunctionDropdown("switchMetaData");
+ jsEditor.RunJSObj();
+ agHelper.Sleep(2000);
+ agHelper.GetNClick(jsEditor._logsTab);
+ debuggerHelper.DebuggerLogsFilter("JSObject1.metaDataApiTest");
+ debuggerHelper.DoesConsoleLogExist("Hello from setTimeout inside API");
});
});
});
diff --git a/app/client/cypress/e2e/Regression/ServerSide/JsFunctionExecution/SetTimeout_spec.ts b/app/client/cypress/e2e/Regression/ServerSide/JsFunctionExecution/SetTimeout_spec.ts
index 763f2d7551..ed00b97f52 100644
--- a/app/client/cypress/e2e/Regression/ServerSide/JsFunctionExecution/SetTimeout_spec.ts
+++ b/app/client/cypress/e2e/Regression/ServerSide/JsFunctionExecution/SetTimeout_spec.ts
@@ -1,9 +1,11 @@
-import { ObjectsRegistry } from "../../../../support/Objects/Registry";
-const jsEditor = ObjectsRegistry.JSEditor;
-const agHelper = ObjectsRegistry.AggregateHelper;
-const apiPage = ObjectsRegistry.ApiPage;
-const deployMode = ObjectsRegistry.DeployMode;
-const debuggerHelper = ObjectsRegistry.DebuggerHelper;
+import {
+ tedTestConfig,
+ jsEditor,
+ agHelper,
+ apiPage,
+ deployMode,
+ debuggerHelper,
+} from "../../../../support/Objects/ObjectsCore";
let userName: string;
@@ -145,10 +147,9 @@ describe("Tests setTimeout API", function () {
});
it("6. Access to args passed into success/error callback functions in API.run when using setTimeout", () => {
- cy.fixture("datasources").then((datasourceFormData: any) => {
- apiPage.CreateAndFillApi(datasourceFormData["mockApiUrl"]);
- jsEditor.CreateJSObject(
- `export default {
+ apiPage.CreateAndFillApi(tedTestConfig.mockApiUrl);
+ jsEditor.CreateJSObject(
+ `export default {
myVar1: [],
myVar2: {},
myFun1: (x) => {
@@ -168,42 +169,40 @@ describe("Tests setTimeout API", function () {
});
}
}`,
- {
- paste: true,
- completeReplace: true,
- toRun: false,
- shouldCreateNewJSObj: true,
- prettify: true,
- },
- );
- jsEditor.RenameJSObjFromPane("Timeouts");
- agHelper.Sleep(2000);
- jsEditor.RunJSObj();
- agHelper.Sleep(3000);
+ {
+ paste: true,
+ completeReplace: true,
+ toRun: false,
+ shouldCreateNewJSObj: true,
+ prettify: true,
+ },
+ );
+ jsEditor.RenameJSObjFromPane("Timeouts");
+ agHelper.Sleep(2000);
+ jsEditor.RunJSObj();
+ agHelper.Sleep(3000);
- cy.wait("@postExecute").then((interception: any) => {
- //Js function to match any name returned from API
- userName = JSON.stringify(
- interception.response.body.data.body[0].name,
- ).replace(/['"]+/g, ""); //removing double quotes
- agHelper.AssertContains(userName);
- });
+ cy.wait("@postExecute").then((interception: any) => {
+ //Js function to match any name returned from API
+ userName = JSON.stringify(
+ interception.response.body.data.body[0].name,
+ ).replace(/['"]+/g, ""); //removing double quotes
+ agHelper.AssertContains(userName);
+ });
- agHelper.Sleep(2000);
- jsEditor.SelectFunctionDropdown("myFun2");
- jsEditor.RunJSObj();
- agHelper.Sleep(3000);
- cy.wait("@postExecute").then((interception: any) => {
- userName = JSON.stringify(
- interception.response.body.data.body[0].name,
- ).replace(/['"]+/g, "");
- agHelper.AssertContains(userName);
- });
+ agHelper.Sleep(2000);
+ jsEditor.SelectFunctionDropdown("myFun2");
+ jsEditor.RunJSObj();
+ agHelper.Sleep(3000);
+ cy.wait("@postExecute").then((interception: any) => {
+ userName = JSON.stringify(
+ interception.response.body.data.body[0].name,
+ ).replace(/['"]+/g, "");
+ agHelper.AssertContains(userName);
});
});
it("7. Verifies whether setTimeout executes on page load", () => {
- //apiPage.CreateAndFillApi(agHelper.mockApiUrl);
jsEditor.CreateJSObject(
`export default {
myVar1: [],
diff --git a/app/client/cypress/e2e/Sanity/Datasources/Airtable_Basic_Spec.ts b/app/client/cypress/e2e/Sanity/Datasources/Airtable_Basic_Spec.ts
index 6d94b185d6..3c4cb5f775 100644
--- a/app/client/cypress/e2e/Sanity/Datasources/Airtable_Basic_Spec.ts
+++ b/app/client/cypress/e2e/Sanity/Datasources/Airtable_Basic_Spec.ts
@@ -3,12 +3,12 @@ import {
entityExplorer,
entityItems,
dataSources,
- hostPort,
+ tedTestConfig,
assertHelper,
} from "../../../support/Objects/ObjectsCore";
let dsName: any, jsonSpecies: any, offset: any, insertedRecordId: any;
-describe("excludeForAirgap", "Validate Airtable Ds", () => {
+describe.skip("excludeForAirgap", "Validate Airtable Ds", () => {
before("Create a new Airtable DS", () => {
dataSources.CreateDataSource("Airtable", true, false);
cy.get("@dsName").then(($dsName) => {
@@ -27,12 +27,12 @@ describe("excludeForAirgap", "Validate Airtable Ds", () => {
"List records",
);
- agHelper.EnterValue(hostPort.AirtableBase, {
+ agHelper.EnterValue(tedTestConfig.AirtableBase, {
propFieldName: "",
directInput: false,
inputFieldName: "Base ID ",
});
- agHelper.EnterValue(hostPort.AirtableTable, {
+ agHelper.EnterValue(tedTestConfig.AirtableTable, {
propFieldName: "",
directInput: false,
inputFieldName: "Table name",
@@ -236,7 +236,7 @@ describe("excludeForAirgap", "Validate Airtable Ds", () => {
});
dataSources.RunQuery({ toValidateResponse: false }); //For CI failure!
- agHelper.Sleep();
+ agHelper.Sleep(3000);
dataSources.RunQuery();
cy.get("@postExecute").then((resObj: any) => {
diff --git a/app/client/cypress/fixtures/datasources.json b/app/client/cypress/fixtures/datasources.json
index f84aa6368f..86d6f6f066 100644
--- a/app/client/cypress/fixtures/datasources.json
+++ b/app/client/cypress/fixtures/datasources.json
@@ -64,7 +64,6 @@
"AirtableBase": "appubHrVbovcudwN6",
"AirtableTable": "tblsFCQSskVFf7xNd",
- "mockApiUrl": "http://host.docker.internal:5001/v1/mock-api?records=10",
"echoApiUrl": "http://host.docker.internal:5001/v1/mock-api/echo",
"randomCatfactUrl": "http://host.docker.internal:5001/v1/catfact/random",
"multipartAPI": "http://host.docker.internal:5001/v1/mock-api/echo-multipart",
diff --git a/app/client/cypress/support/Objects/ObjectsCore.ts b/app/client/cypress/support/Objects/ObjectsCore.ts
index 1c8b43a581..f6ee30202c 100644
--- a/app/client/cypress/support/Objects/ObjectsCore.ts
+++ b/app/client/cypress/support/Objects/ObjectsCore.ts
@@ -29,6 +29,6 @@ export const onboarding = ObjectsRegistry.Onboarding;
export const autoLayout = ObjectsRegistry.AutoLayout;
export const draggableWidgets = WIDGET;
export const fakerHelper = ObjectsRegistry.FakerHelper;
-export const hostPort = ObjectsRegistry.DefaultHostPort;
+export const tedTestConfig = ObjectsRegistry.TEDTestConfigs;
export const entityItems = EntityItems;
export const tabs = ObjectsRegistry.Tabs;
diff --git a/app/client/cypress/support/Objects/Registry.ts b/app/client/cypress/support/Objects/Registry.ts
index 760ac21d1d..0ca9792811 100644
--- a/app/client/cypress/support/Objects/Registry.ts
+++ b/app/client/cypress/support/Objects/Registry.ts
@@ -23,7 +23,7 @@ import { EmbedSettings } from "../Pages/AppSettings/EmbedSettings";
import { Templates } from "../Pages/Templates";
import { Onboarding } from "../Pages/Onboarding";
import { AutoLayout } from "../Pages/AutoLayout";
-import { DefaultHostPort } from "./Hostport";
+import { TEDTestConfigs } from "./TestConfigs";
import { AssertHelper } from "../Pages/AssertHelper";
import { ReusableHelper } from "./ReusableHelper";
import { Tabs } from "../Pages/Tabs";
@@ -253,12 +253,12 @@ export class ObjectsRegistry {
return ObjectsRegistry.autoLayout__;
}
- private static defaultHostPort__: DefaultHostPort;
- static get DefaultHostPort(): DefaultHostPort {
- if (ObjectsRegistry.defaultHostPort__ === undefined) {
- ObjectsRegistry.defaultHostPort__ = new DefaultHostPort();
+ private static tedTestConfigs__: TEDTestConfigs;
+ static get TEDTestConfigs(): TEDTestConfigs {
+ if (ObjectsRegistry.tedTestConfigs__ === undefined) {
+ ObjectsRegistry.tedTestConfigs__ = new TEDTestConfigs();
}
- return ObjectsRegistry.defaultHostPort__;
+ return ObjectsRegistry.tedTestConfigs__;
}
}
diff --git a/app/client/cypress/support/Objects/Hostport.ts b/app/client/cypress/support/Objects/TestConfigs.ts
similarity index 99%
rename from app/client/cypress/support/Objects/Hostport.ts
rename to app/client/cypress/support/Objects/TestConfigs.ts
index 37411f7705..4dc1a600c1 100644
--- a/app/client/cypress/support/Objects/Hostport.ts
+++ b/app/client/cypress/support/Objects/TestConfigs.ts
@@ -1,4 +1,4 @@
-export class DefaultHostPort {
+export class TEDTestConfigs {
mongo_authenticationAuthtype = "SCRAM-SHA-1";
mongo_host = "host.docker.internal";
mongo_port = 28017;
diff --git a/app/client/cypress/support/Pages/AssertHelper.ts b/app/client/cypress/support/Pages/AssertHelper.ts
index c1e7b7351e..d8b68d9657 100644
--- a/app/client/cypress/support/Pages/AssertHelper.ts
+++ b/app/client/cypress/support/Pages/AssertHelper.ts
@@ -30,7 +30,7 @@ export class AssertHelper extends ReusableHelper {
expect(doc.readyState).to.equal("complete");
}),
);
- cy.window().should("have.property", "onload");
+ cy.window({ timeout: 60000 }).should("have.property", "onload");
}
public AssertDelete(entityType: EntityItemsType) {
@@ -74,8 +74,8 @@ export class AssertHelper extends ReusableHelper {
// "response.body.responseMeta.status",
// expectedStatus,
// );
- this.Sleep(); //Wait a bit for call to finish!
- return cy.wait(this.GetAliasName(aliasName));
+ this.Sleep(2000); //Wait a bit for call to finish!
+ return cy.wait(this.GetAliasName(aliasName), { responseTimeout: 60000 });
}
public AssertNetworkStatus(aliasName: string, expectedStatus = 200) {
diff --git a/app/client/cypress/support/Pages/DataSources.ts b/app/client/cypress/support/Pages/DataSources.ts
index 744b2eef04..1ae344fb48 100644
--- a/app/client/cypress/support/Pages/DataSources.ts
+++ b/app/client/cypress/support/Pages/DataSources.ts
@@ -35,14 +35,14 @@ export class DataSources {
private ee = ObjectsRegistry.EntityExplorer;
private locator = ObjectsRegistry.CommonLocators;
private apiPage = ObjectsRegistry.ApiPage;
- private hp = ObjectsRegistry.DefaultHostPort;
+ private tedTestConfig = ObjectsRegistry.TEDTestConfigs;
private assertHelper = ObjectsRegistry.AssertHelper;
public ContainerKVP = (containerName: string) => {
return {
- MsSql: this.hp.mssql_docker(containerName),
- Arango: this.hp.arango_docker(containerName),
- Elasticsearch: this.hp.elastic_docker(containerName),
+ MsSql: this.tedTestConfig.mssql_docker(containerName),
+ Arango: this.tedTestConfig.arango_docker(containerName),
+ Elasticsearch: this.tedTestConfig.elastic_docker(containerName),
};
}; //Container KeyValuePair
@@ -402,22 +402,22 @@ export class DataSources {
password = "",
) {
const hostAddress = shouldAddTrailingSpaces
- ? this.hp.postgres_host + " "
- : this.hp.postgres_host;
+ ? this.tedTestConfig.postgres_host + " "
+ : this.tedTestConfig.postgres_host;
const databaseName = shouldAddTrailingSpaces
- ? this.hp.postgres_databaseName + " "
- : this.hp.postgres_databaseName;
+ ? this.tedTestConfig.postgres_databaseName + " "
+ : this.tedTestConfig.postgres_databaseName;
this.agHelper.UpdateInputValue(
this._port,
- this.hp.postgres_port.toString(),
+ this.tedTestConfig.postgres_port.toString(),
);
this.agHelper.UpdateInputValue(this._host, hostAddress);
cy.get(this._databaseName).clear().type(databaseName);
cy.get(this._username).type(
- username == "" ? this.hp.postgres_username : username,
+ username == "" ? this.tedTestConfig.postgres_username : username,
);
cy.get(this._password).type(
- password == "" ? this.hp.postgres_username : password,
+ password == "" ? this.tedTestConfig.postgres_username : password,
);
this.ValidateNSelectDropdown("SSL mode", "Default");
}
@@ -428,56 +428,79 @@ export class DataSources {
password = "",
) {
const hostAddress = shouldAddTrailingSpaces
- ? this.hp.oracle_host + " "
- : this.hp.oracle_host;
+ ? this.tedTestConfig.oracle_host + " "
+ : this.tedTestConfig.oracle_host;
const databaseName = shouldAddTrailingSpaces
- ? this.hp.oracle_name + " "
- : this.hp.oracle_name;
+ ? this.tedTestConfig.oracle_name + " "
+ : this.tedTestConfig.oracle_name;
this.agHelper.UpdateInputValue(this._host, hostAddress);
- this.agHelper.UpdateInputValue(this._port, this.hp.oracle_port.toString());
+ this.agHelper.UpdateInputValue(
+ this._port,
+ this.tedTestConfig.oracle_port.toString(),
+ );
cy.get(this._databaseName).clear().type(databaseName);
cy.get(this._username).type(
- username == "" ? this.hp.oracle_username : username,
+ username == "" ? this.tedTestConfig.oracle_username : username,
);
cy.get(this._password).type(
- password == "" ? this.hp.oracle_password : password,
+ password == "" ? this.tedTestConfig.oracle_password : password,
);
}
public FillMongoDSForm(shouldAddTrailingSpaces = false) {
const hostAddress = shouldAddTrailingSpaces
- ? this.hp.mongo_host + " "
- : this.hp.mongo_host;
+ ? this.tedTestConfig.mongo_host + " "
+ : this.tedTestConfig.mongo_host;
this.agHelper.UpdateInputValue(this._host, hostAddress);
- this.agHelper.UpdateInputValue(this._port, this.hp.mongo_port.toString());
- cy.get(this._databaseName).clear().type(this.hp.mongo_databaseName);
+ this.agHelper.UpdateInputValue(
+ this._port,
+ this.tedTestConfig.mongo_port.toString(),
+ );
+ cy.get(this._databaseName)
+ .clear()
+ .type(this.tedTestConfig.mongo_databaseName);
}
public FillMySqlDSForm(shouldAddTrailingSpaces = false) {
const hostAddress = shouldAddTrailingSpaces
- ? this.hp.mysql_host + " "
- : this.hp.mysql_host;
+ ? this.tedTestConfig.mysql_host + " "
+ : this.tedTestConfig.mysql_host;
const databaseName = shouldAddTrailingSpaces
- ? this.hp.mysql_databaseName + " "
- : this.hp.mysql_databaseName;
+ ? this.tedTestConfig.mysql_databaseName + " "
+ : this.tedTestConfig.mysql_databaseName;
this.agHelper.UpdateInputValue(this._host, hostAddress);
- this.agHelper.UpdateInputValue(this._port, this.hp.mysql_port.toString());
+ this.agHelper.UpdateInputValue(
+ this._port,
+ this.tedTestConfig.mysql_port.toString(),
+ );
cy.get(this._databaseName).clear().type(databaseName);
- this.agHelper.UpdateInputValue(this._username, this.hp.mysql_username);
- cy.get(this._password).type(this.hp.mysql_password);
+ this.agHelper.UpdateInputValue(
+ this._username,
+ this.tedTestConfig.mysql_username,
+ );
+ cy.get(this._password).type(this.tedTestConfig.mysql_password);
}
public FillMsSqlDSForm() {
- this.agHelper.UpdateInputValue(this._host, this.hp.mssql_host);
- this.agHelper.UpdateInputValue(this._port, this.hp.mssql_port.toString());
+ this.agHelper.UpdateInputValue(this._host, this.tedTestConfig.mssql_host);
+ this.agHelper.UpdateInputValue(
+ this._port,
+ this.tedTestConfig.mssql_port.toString(),
+ );
this.agHelper.ClearTextField(this._databaseName);
// this.agHelper.UpdateInputValue(
// this._databaseName,
// datasourceFormData["mssql-databaseName"],
// ); //Commenting until MsSQL is init loaded into container
- this.agHelper.UpdateInputValue(this._username, this.hp.mssql_username);
- this.agHelper.UpdateInputValue(this._password, this.hp.mssql_password);
+ this.agHelper.UpdateInputValue(
+ this._username,
+ this.tedTestConfig.mssql_username,
+ );
+ this.agHelper.UpdateInputValue(
+ this._password,
+ this.tedTestConfig.mssql_password,
+ );
}
public FillAirtableDSForm() {
@@ -494,14 +517,23 @@ export class DataSources {
}
public FillArangoDSForm() {
- this.agHelper.UpdateInputValue(this._host, this.hp.arango_host);
- this.agHelper.UpdateInputValue(this._port, this.hp.arango_port.toString());
+ this.agHelper.UpdateInputValue(this._host, this.tedTestConfig.arango_host);
+ this.agHelper.UpdateInputValue(
+ this._port,
+ this.tedTestConfig.arango_port.toString(),
+ );
//Validating db name is _system, currently unable to create DB via curl in Arango
this.agHelper
.GetText(this._databaseName, "val")
.then(($dbName) => expect($dbName).to.eq("_system"));
- this.agHelper.UpdateInputValue(this._username, this.hp.arango_username);
- this.agHelper.UpdateInputValue(this._password, this.hp.arango_password);
+ this.agHelper.UpdateInputValue(
+ this._username,
+ this.tedTestConfig.arango_username,
+ );
+ this.agHelper.UpdateInputValue(
+ this._password,
+ this.tedTestConfig.arango_password,
+ );
}
public FillCurlNImport(value: string) {
@@ -520,11 +552,11 @@ export class DataSources {
public FillFirestoreDSForm() {
this.agHelper.UpdateInput(
this.locator._inputFieldByName("Database URL"),
- this.hp.firestore_database_url,
+ this.tedTestConfig.firestore_database_url,
);
this.agHelper.UpdateInput(
this.locator._inputFieldByName("Project Id"),
- this.hp.firestore_projectID,
+ this.tedTestConfig.firestore_projectID,
);
// cy.fixture("firestore-ServiceAccCreds").then((json: any) => {
// let ServiceAccCreds = JSON.parse(
@@ -544,15 +576,24 @@ export class DataSources {
}
public FillElasticSearchDSForm() {
- this.agHelper.UpdateInputValue(this._host, this.hp.elastic_host);
- this.agHelper.UpdateInputValue(this._port, this.hp.elastic_port.toString());
- this.agHelper.UpdateInputValue(this._username, this.hp.elastic_username);
- this.agHelper.UpdateInputValue(this._password, this.hp.elastic_password);
+ this.agHelper.UpdateInputValue(this._host, this.tedTestConfig.elastic_host);
+ this.agHelper.UpdateInputValue(
+ this._port,
+ this.tedTestConfig.elastic_port.toString(),
+ );
+ this.agHelper.UpdateInputValue(
+ this._username,
+ this.tedTestConfig.elastic_username,
+ );
+ this.agHelper.UpdateInputValue(
+ this._password,
+ this.tedTestConfig.elastic_password,
+ );
}
public FillUnAuthenticatedGraphQLDSForm() {
this.agHelper.GetNClick(this._createBlankGraphQL);
- this.apiPage.EnterURL(this.hp.GraphqlApiUrl_TED);
+ this.apiPage.EnterURL(this.tedTestConfig.GraphqlApiUrl_TED);
this.assertHelper.AssertNetworkStatus("@createNewApi", 201);
}
@@ -565,7 +606,7 @@ export class DataSources {
this.CreatePlugIn("Authenticated GraphQL API");
this.agHelper.UpdateInput(
this.locator._inputFieldByName("URL"),
- this.hp.GraphqlApiUrl_TED,
+ this.tedTestConfig.GraphqlApiUrl_TED,
);
this.agHelper.UpdateInputValue(this._graphQLHeaderKey, hKey);
@@ -579,8 +620,11 @@ export class DataSources {
}
public FillRedisDSForm() {
- this.agHelper.UpdateInputValue(this._host, this.hp.redis_host);
- this.agHelper.UpdateInputValue(this._port, this.hp.redis_port.toString());
+ this.agHelper.UpdateInputValue(this._host, this.tedTestConfig.redis_host);
+ this.agHelper.UpdateInputValue(
+ this._port,
+ this.tedTestConfig.redis_port.toString(),
+ );
}
public FillS3DSForm() {
@@ -1177,7 +1221,7 @@ export class DataSources {
public FillAuthAPIUrl() {
this.agHelper.UpdateInput(
this.locator._inputFieldByName("URL"),
- this.hp.authenticatedApiUrl,
+ this.tedTestConfig.authenticatedApiUrl,
);
}
@@ -1215,7 +1259,7 @@ export class DataSources {
}
public FillMongoDatasourceFormWithURI() {
- const uri = this.hp.mongo_uri;
+ const uri = this.tedTestConfig.mongo_uri;
this.ValidateNSelectDropdown(
"Use mongo connection string URI",
"No",
@@ -1232,28 +1276,32 @@ export class DataSources {
// Login to TED OAuth
let formData = new FormData();
- formData.append("username", this.hp.OAuth_Username);
- cy.request("POST", this.hp.OAuth_Host, formData).then((response) => {
- expect(response.status).to.equal(200);
- });
+ formData.append("username", this.tedTestConfig.OAuth_Username);
+ cy.request("POST", this.tedTestConfig.OAuth_Host, formData).then(
+ (response) => {
+ expect(response.status).to.equal(200);
+ },
+ );
// Create client
let clientData = new FormData();
clientData.append("client_name", "appsmith_cs_post");
clientData.append("client_uri", "http://localhost/");
clientData.append("scope", "profile");
- clientData.append("redirect_uri", this.hp.OAuth_RedirectUrl);
+ clientData.append("redirect_uri", this.tedTestConfig.OAuth_RedirectUrl);
clientData.append("grant_type", grantType);
clientData.append("response_type", "code");
clientData.append("token_endpoint_auth_method", "client_secret_post");
- cy.request("POST", this.hp.OAuth_Host + "/create_client", clientData).then(
- (response) => {
- expect(response.status).to.equal(200);
- },
- );
+ cy.request(
+ "POST",
+ this.tedTestConfig.OAuth_Host + "/create_client",
+ clientData,
+ ).then((response) => {
+ expect(response.status).to.equal(200);
+ });
// Get Client Credentials
- cy.request("GET", this.hp.OAuth_Host).then((response) => {
+ cy.request("GET", this.tedTestConfig.OAuth_Host).then((response) => {
clientId = response.body.split("client_id: ");
clientId = clientId[1].split("client_secret: ");
clientSecret = clientId[1].split("");
@@ -1297,7 +1345,7 @@ export class DataSources {
// Fill Auth Form
this.agHelper.UpdateInput(
this.locator._inputFieldByName("URL"),
- this.hp.OAuth_ApiUrl,
+ this.tedTestConfig.OAuth_ApiUrl,
);
this.agHelper.GetNClick(this._authType);
this.agHelper.GetNClick(this._oauth2);
@@ -1309,7 +1357,7 @@ export class DataSources {
this.agHelper.UpdateInput(
this.locator._inputFieldByName("Access token URL"),
- this.hp.OAUth_AccessTokenUrl,
+ this.tedTestConfig.OAUth_AccessTokenUrl,
);
this.agHelper.UpdateInput(
@@ -1326,7 +1374,7 @@ export class DataSources {
);
this.agHelper.UpdateInput(
this.locator._inputFieldByName("Authorization URL"),
- this.hp.OAuth_AuthUrl,
+ this.tedTestConfig.OAuth_AuthUrl,
);
}
diff --git a/app/client/cypress/support/Pages/EntityExplorer.ts b/app/client/cypress/support/Pages/EntityExplorer.ts
index 5fe62619da..1de036be78 100644
--- a/app/client/cypress/support/Pages/EntityExplorer.ts
+++ b/app/client/cypress/support/Pages/EntityExplorer.ts
@@ -302,7 +302,7 @@ export class EntityExplorer {
this.agHelper.Sleep(500);
}
- public DragDropWidgetNVerify(
+ private DragNDropWidget(
widgetType: string,
x = 300,
y = 100,
@@ -342,6 +342,16 @@ export class EntityExplorer {
)
.first()
.trigger("mouseup", x, y, { eventConstructor: "MouseEvent" });
+ }
+
+ public DragDropWidgetNVerify(
+ widgetType: string,
+ x = 300,
+ y = 100,
+ parentWidgetType = "",
+ dropTargetId = "",
+ ) {
+ this.DragNDropWidget(widgetType, x, y, parentWidgetType, dropTargetId);
this.agHelper.AssertAutoSave(); //settling time for widget on canvas!
if (widgetType === "modalwidget") {
cy.get(".t--modal-widget").should("exist");
diff --git a/app/client/cypress/support/Pages/GitSync.ts b/app/client/cypress/support/Pages/GitSync.ts
index 0d1692887b..b30443328b 100644
--- a/app/client/cypress/support/Pages/GitSync.ts
+++ b/app/client/cypress/support/Pages/GitSync.ts
@@ -5,7 +5,7 @@ const GITHUB_API_BASE = "https://api.github.com";
export class GitSync {
public agHelper = ObjectsRegistry.AggregateHelper;
public locator = ObjectsRegistry.CommonLocators;
- private hostPort = ObjectsRegistry.DefaultHostPort;
+ private tedTestConfig = ObjectsRegistry.TEDTestConfigs;
private assertHelper = ObjectsRegistry.AssertHelper;
private _connectGitBottomBar = ".t--connect-git-bottom-bar";
@@ -72,7 +72,7 @@ export class GitSync {
public CreateTestGiteaRepo(repo: string, privateFlag = false) {
cy.request({
method: "POST",
- url: `${this.hostPort.GITEA_API_BASE_TED}:${this.hostPort.GITEA_API_PORT_TED}/api/v1/org/Cypress/repos`,
+ url: `${this.tedTestConfig.GITEA_API_BASE_TED}:${this.tedTestConfig.GITEA_API_PORT_TED}/api/v1/org/Cypress/repos`,
headers: {
Authorization: `token ${Cypress.env("GITEA_TOKEN")}`,
},
@@ -97,7 +97,7 @@ export class GitSync {
);
this.agHelper.TypeText(
this._gitRepoInput,
- `${this.hostPort.GITEA_API_URL_TED}/${repo}.git`,
+ `${this.tedTestConfig.GITEA_API_URL_TED}/${repo}.git`,
//`git@github.com:${owner}/${repo}.git`,
);
@@ -109,7 +109,7 @@ export class GitSync {
// fetch the generated key and post to the github repo
cy.request({
method: "POST",
- url: `${this.hostPort.GITEA_API_BASE_TED}:${this.hostPort.GITEA_API_PORT_TED}/api/v1/repos/Cypress/${repo}/keys`,
+ url: `${this.tedTestConfig.GITEA_API_BASE_TED}:${this.tedTestConfig.GITEA_API_PORT_TED}/api/v1/repos/Cypress/${repo}/keys`,
headers: {
Authorization: `token ${Cypress.env("GITEA_TOKEN")}`,
},
@@ -139,7 +139,7 @@ export class GitSync {
DeleteTestGithubRepo(repo: any) {
cy.request({
method: "DELETE",
- url: `${this.hostPort.GITEA_API_BASE_TED}:${this.hostPort.GITEA_API_PORT_TED}/api/v1/repos/Cypress/${repo}`,
+ url: `${this.tedTestConfig.GITEA_API_BASE_TED}:${this.tedTestConfig.GITEA_API_PORT_TED}/api/v1/repos/Cypress/${repo}`,
headers: {
Authorization: `token ${Cypress.env("GITEA_TOKEN")}`,
},
@@ -269,7 +269,7 @@ export class GitSync {
// fetch the generated key and post to the github repo
cy.request({
method: "POST",
- url: `http://${this.hostPort.GITEA_API_BASE_TED}:${this.hostPort.GITEA_API_PORT_TED}/v1/gitserver/addgitssh`,
+ url: `http://${this.tedTestConfig.GITEA_API_BASE_TED}:${this.tedTestConfig.GITEA_API_PORT_TED}/v1/gitserver/addgitssh`,
//body: formdata,
body: {
sshkey: generatedKey,
@@ -330,7 +330,7 @@ export class GitSync {
cy.request({
method: "GET",
url:
- `http://${this.hostPort.GITEA_API_BASE_TED}:${this.hostPort.GITEA_API_PORT_TED}/v1/gitserver/addrepo?reponame=` +
+ `http://${this.tedTestConfig.GITEA_API_BASE_TED}:${this.tedTestConfig.GITEA_API_PORT_TED}/v1/gitserver/addrepo?reponame=` +
repo,
}).then((response) => {
remoteUrl = JSON.stringify(response.body).replace(/['"]+/g, "");
diff --git a/app/client/cypress/support/Pages/Onboarding.ts b/app/client/cypress/support/Pages/Onboarding.ts
index 60e3a3deb6..d219054100 100644
--- a/app/client/cypress/support/Pages/Onboarding.ts
+++ b/app/client/cypress/support/Pages/Onboarding.ts
@@ -24,6 +24,7 @@ export class Onboarding {
this._aggregateHelper.AssertElementVisible(
OnboardingLocator.datasourcePage,
);
+ this.closeIntroModal();
this._aggregateHelper.AssertElementAbsence(
OnboardingLocator.introModal,
10000,
diff --git a/app/client/cypress/support/Pages/PropertyPane.ts b/app/client/cypress/support/Pages/PropertyPane.ts
index 1c71a727ee..7894de15ff 100644
--- a/app/client/cypress/support/Pages/PropertyPane.ts
+++ b/app/client/cypress/support/Pages/PropertyPane.ts
@@ -291,12 +291,15 @@ export class PropertyPane {
propFieldName: string,
valueToEnter: string,
toVerifySave = true,
+ toValidateNetworkCall = true,
) {
this.agHelper.UpdateCodeInput(
this.locator._existingFieldTextByName(propFieldName),
valueToEnter,
);
toVerifySave && this.agHelper.AssertAutoSave(); //Allowing time for saving entered value
+ toValidateNetworkCall &&
+ this.assertHelper.AssertNetworkStatus("@updateLayout");
}
public ValidatePropertyFieldValue(
diff --git a/app/client/cypress/support/gitSync.js b/app/client/cypress/support/gitSync.js
index c2aed6ee97..b28980c0cf 100644
--- a/app/client/cypress/support/gitSync.js
+++ b/app/client/cypress/support/gitSync.js
@@ -9,7 +9,7 @@ import { ObjectsRegistry } from "../support/Objects/Registry";
let gitSync = ObjectsRegistry.GitSync,
agHelper = ObjectsRegistry.AggregateHelper,
- hostPort = ObjectsRegistry.DefaultHostPort;
+ tedTestConfig = ObjectsRegistry.TEDTestConfigs;
const commonLocators = require("../locators/commonlocators.json");
const GITHUB_API_BASE = "https://api.github.com";
@@ -342,7 +342,7 @@ Cypress.Commands.add(
);
cy.get(gitSyncLocators.gitRepoInput).type(
//`git@github.com:${owner}/${repo}.git`,
- `${hostPort.GITEA_API_URL_TED}/${repo}.git`,
+ `${tedTestConfig.GITEA_API_URL_TED}/${repo}.git`,
);
cy.get(gitSyncLocators.generateDeployKeyBtn).click();
cy.wait(`@generateKey-${repo}`).then((result) => {
@@ -365,7 +365,7 @@ Cypress.Commands.add(
cy.request({
method: "POST",
- url: `${hostPort.GITEA_API_BASE_TED}:${hostPort.GITEA_API_PORT_TED}/api/v1/repos/Cypress/${repo}/keys`,
+ url: `${tedTestConfig.GITEA_API_BASE_TED}:${tedTestConfig.GITEA_API_PORT_TED}/api/v1/repos/Cypress/${repo}/keys`,
headers: {
Authorization: `token ${Cypress.env("GITEA_TOKEN")}`,
},
@@ -475,7 +475,7 @@ Cypress.Commands.add(
cy.request({
method: "POST",
- url: `${hostPort.GITEA_API_BASE_TED}:${hostPort.GITEA_API_PORT_TED}/api/v1/repos/Cypress/${repo}/keys`,
+ url: `${tedTestConfig.GITEA_API_BASE_TED}:${tedTestConfig.GITEA_API_PORT_TED}/api/v1/repos/Cypress/${repo}/keys`,
headers: {
Authorization: `token ${Cypress.env("GITEA_TOKEN")}`,
},