Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,12 @@ describe("UI to Code", { tags: ["@tag.JS"] }, () => {
agHelper.GetNClick(propPane._navigateToType("URL"));
agHelper.TypeText(
propPane._actionSelectorFieldByLabel("Enter URL"),
"https://google.com",
"https://www.appsmith.com",
);
agHelper.GetNClick(propPane._actionSelectorPopupClose);
propPane.ValidateJSFieldValue(
"onClick",
`{{showAlert('Hello!', '');navigateTo('https://google.com', {}, 'SAME_WINDOW');}}`,
`{{showAlert('Hello!', '');navigateTo('https://www.appsmith.com', {}, 'SAME_WINDOW');}}`,
);

// Add third action
Expand All @@ -80,7 +80,7 @@ describe("UI to Code", { tags: ["@tag.JS"] }, () => {
// Validate the code
propPane.ValidateJSFieldValue(
"onClick",
`{{showAlert('Hello!', '');navigateTo('https://google.com', {}, 'SAME_WINDOW');storeValue('secret-key', 'secret-value');copyToClipboard('text to copy');}}`,
`{{showAlert('Hello!', '');navigateTo('https://www.appsmith.com', {}, 'SAME_WINDOW');storeValue('secret-key', 'secret-value');copyToClipboard('text to copy');}}`,
);

// Delete the third action
Expand All @@ -97,7 +97,7 @@ describe("UI to Code", { tags: ["@tag.JS"] }, () => {
// Assert the code for the remaining actions
propPane.ValidateJSFieldValue(
"onClick",
`{{showAlert('Hello!', '');navigateTo('https://google.com', {}, 'SAME_WINDOW');copyToClipboard('text to copy');}}`,
`{{showAlert('Hello!', '');navigateTo('https://www.appsmith.com', {}, 'SAME_WINDOW');copyToClipboard('text to copy');}}`,
);

// Delete the first action
Expand All @@ -113,7 +113,7 @@ describe("UI to Code", { tags: ["@tag.JS"] }, () => {
// Assert the code for the remaining actions
propPane.ValidateJSFieldValue(
"onClick",
`{{navigateTo('https://google.com', {}, 'SAME_WINDOW');copyToClipboard('text to copy');}}`,
`{{navigateTo('https://www.appsmith.com', {}, 'SAME_WINDOW');copyToClipboard('text to copy');}}`,
);
});

Expand All @@ -132,13 +132,13 @@ describe("UI to Code", { tags: ["@tag.JS"] }, () => {
agHelper.GetNClick(propPane._navigateToType("URL"));
agHelper.TypeText(
propPane._actionSelectorFieldByLabel("Enter URL"),
"https://google.com",
"https://www.appsmith.com",
);
agHelper.GetNClick(propPane._actionSelectorPopupClose);

propPane.ValidateJSFieldValue(
"onClick",
`{{showAlert('Hello!', '');navigateTo('https://google.com', {}, 'SAME_WINDOW');}}`,
`{{showAlert('Hello!', '');navigateTo('https://www.appsmith.com', {}, 'SAME_WINDOW');}}`,
);

// Add third action
Expand All @@ -165,7 +165,7 @@ describe("UI to Code", { tags: ["@tag.JS"] }, () => {

propPane.ValidateJSFieldValue(
"onClick",
`{{showAlert('Hello!', '');navigateTo('https://google.com', {}, 'SAME_WINDOW');storeValue('secret-key', 'secret-value');copyToClipboard('text to copy');}}`,
`{{showAlert('Hello!', '');navigateTo('https://www.appsmith.com', {}, 'SAME_WINDOW');storeValue('secret-key', 'secret-value');copyToClipboard('text to copy');}}`,
);

// Delete the third action
Expand Down Expand Up @@ -197,7 +197,7 @@ describe("UI to Code", { tags: ["@tag.JS"] }, () => {

propPane.ValidateJSFieldValue(
"onClick",
`{{showAlert('Hello!', '');navigateTo('https://google.com', {}, 'SAME_WINDOW');storeValue('secret-key', 'secret-value');copyToClipboard('text to copy');}}`,
`{{showAlert('Hello!', '');navigateTo('https://www.appsmith.com', {}, 'SAME_WINDOW');storeValue('secret-key', 'secret-value');copyToClipboard('text to copy');}}`,
);
});

Expand All @@ -216,13 +216,13 @@ describe("UI to Code", { tags: ["@tag.JS"] }, () => {
agHelper.GetNClick(propPane._navigateToType("URL"));
agHelper.TypeText(
propPane._actionSelectorFieldByLabel("Enter URL"),
"https://google.com",
"https://www.appsmith.com",
);
agHelper.GetNClick(propPane._actionSelectorPopupClose);

propPane.ValidateJSFieldValue(
"onClick",
`{{showAlert('Hello!', '');navigateTo('https://google.com', {}, 'SAME_WINDOW');}}`,
`{{showAlert('Hello!', '');navigateTo('https://www.appsmith.com', {}, 'SAME_WINDOW');}}`,
);

// Add third action
Expand All @@ -249,7 +249,7 @@ describe("UI to Code", { tags: ["@tag.JS"] }, () => {

propPane.ValidateJSFieldValue(
"onClick",
`{{showAlert('Hello!', '');navigateTo('https://google.com', {}, 'SAME_WINDOW');storeValue('secret-key', 'secret-value');copyToClipboard('text to copy');}}`,
`{{showAlert('Hello!', '');navigateTo('https://www.appsmith.com', {}, 'SAME_WINDOW');storeValue('secret-key', 'secret-value');copyToClipboard('text to copy');}}`,
);

// Delete the third action
Expand Down Expand Up @@ -286,7 +286,7 @@ describe("UI to Code", { tags: ["@tag.JS"] }, () => {

propPane.ValidateJSFieldValue(
"onClick",
`{{navigateTo('https://google.com', {}, 'SAME_WINDOW');copyToClipboard('text to copy');}}`,
`{{navigateTo('https://www.appsmith.com', {}, 'SAME_WINDOW');copyToClipboard('text to copy');}}`,
);
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ describe("Validate basic Promises", { tags: ["@tag.Binding"] }, () => {
deployMode.NavigateBacktoEditor();
agHelper.AddDsl("promisesBtnImgDsl", locators._buttonByText("Submit"));
apiPage.CreateAndFillApi(
"https://picsum.photos/200/300",
"http://host.docker.internal:4200/453-200x300.jpg",
"RandomImy",
30000,
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ describe(
propPane.MoveToTab("Content");

[1, 2, 3, 4, 5].forEach(() => {
apiPage.CreateAndFillApi("http://www.example.com");
apiPage.CreateAndFillApi("https://www.appsmith.com/");
});

EditorNavigation.SelectEntityByName("Table1", EntityType.Widget);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,9 @@ const setterMethodsToTest = [
property: "url",
widget: WIDGET.AUDIO,
actionBinding:
"{{Audio1.setURL('https://www.youtube.com/watch?v=JGwWNGJdvx8')}}",
"{{Audio1.setURL('http://host.docker.internal:4200/bird.mp4')}}",
valueBinding: "{{Audio1.url}}",
expectedValue: "https://www.youtube.com/watch?v=JGwWNGJdvx8",
expectedValue: "http://host.docker.internal:4200/bird.mp4",
},
{
name: "setPlaying",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ const ppt =
const pngImage =
"https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcRb8umIiCU_K6ac-xS-ni4y6SP7XAd8C7Ms3Q&usqp=CAU";
const jpgImage =
"https://img.frentityExplorerpik.com/frentityExplorer-photo/beautiful-scenery-summit-mount-everest-covered-with-snow-white-clouds_181624-21317.jpg?w=1380&t=st=1691154236~exp=1691154836~hmac=35ce7f92dd16711c69509a0edbb23cedb34e49f960f560c77174994b6d5705a0";
"https://community.appsmith.com/sites/default/files/styles/small_thumbnail/public/2024-03/aws-logo.jpg?itok=yG4bpfFs";
const pdf =
"https://www.learningcontainer.com/wp-content/uploads/2019/09/sample-pdf-file.pdf";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,15 @@ describe(
{ tags: ["@tag.Widget", "@tag.Image"] },
function () {
const image = (src: string) => 'img[src="' + src + '"]';
const jpgImg = "https://jpeg.org/images/jpegsystems-home.jpg";
const jpgImg =
"https://community.appsmith.com/sites/default/files/styles/small_thumbnail/public/2024-03/aws-logo.jpg?itok=yG4bpfFs";
const gifImg =
"https://mir-s3-cdn-cf.behance.net/project_modules/max_1200/5eeea355389655.59822ff824b72.gif";
const svgImg = "https://assets.codepen.io/3/kiwi.svg";
const webpImg = "https://www.gstatic.com/webp/gallery/4.sm.webp";
const pngImg = "https://assets.appsmith.com/widgets/default.png";
"https://www.appsmith.com/_next/image?url=https%3A%2F%2Fimages.ctfassets.net%2Flpvian6u6i39%2F5dIHs6B4O8JrcziD01Tzpr%2F080ac2887506afab72a160b897364607%2Fimage-11.gif&w=1080&q=75";
const svgImg = "https://community.appsmith.com/appsmith-community-logo.svg";
const webpImg =
"https://www.appsmith.com/assets/images/animations/widgets/img_0.webp";
const pngImg =
"https://community.appsmith.com/sites/default/files/styles/16_9_card/public/septembercoding-min%20%281%29.png?itok=unYUZ0zm";

before(() => {
entityExplorer.DragDropWidgetNVerify(draggableWidgets.IMAGE);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ describe(
"Image widget - Rotation & Download",
{ tags: ["@tag.Widget", "@tag.Image"] },
function () {
const jpgImg = "https://jpeg.org/images/jpegsystems-home.jpg";
const jpgImg =
"https://community.appsmith.com/sites/default/files/styles/small_thumbnail/public/2024-03/aws-logo.jpg?itok=yG4bpfFs";
before(() => {
entityExplorer.DragDropWidgetNVerify(draggableWidgets.IMAGE);
propPane.UpdatePropertyFieldValue("Image", jpgImg);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ describe(
.invoke("attr", "src")
.should(
"contain",
"https://res.cloudinary.com/drako999/image/upload/v1589196259/default.png",
"http://host.docker.internal:4200/clouddefaultImage.png",
);
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,19 @@ const data = [
{
id: "001",
name: "Blue",
img: "https://assets.appsmith.com/widgets/default.png",
img: "http://host.docker.internal:4200/clouddefaultImage.png",
same: "1",
},
{
id: "002",
name: "Green",
img: "https://assets.appsmith.com/widgets/default.png",
img: "http://host.docker.internal:4200/clouddefaultImage.png",
same: "01",
},
{
id: "003",
name: "Red",
img: "https://assets.appsmith.com/widgets/default.png",
img: "http://host.docker.internal:4200/clouddefaultImage.png",
same: 1,
},
];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,17 @@ const simpleListData1 = [
{
id: "001",
name: "Blue",
img: "https://assets.appsmith.com/widgets/default.png",
img: "http://host.docker.internal:4200/clouddefaultImage.png",
},
{
id: "002",
name: "Green",
img: "https://assets.appsmith.com/widgets/default.png",
img: "http://host.docker.internal:4200/clouddefaultImage.png",
},
{
id: "003",
name: "Red",
img: "https://assets.appsmith.com/widgets/default.png",
img: "http://host.docker.internal:4200/clouddefaultImage.png",
},
];

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,17 @@ describe(
`{{[{
id: "001",
name: "Blue",
img: "https://assets.appsmith.com/widgets/default.png",
img: "http://host.docker.internal:4200/clouddefaultImage.png",
},
{
id: "002",
name: "Green",
img: "https://assets.appsmith.com/widgets/default.png",
img: "http://host.docker.internal:4200/clouddefaultImage.png",
},
{
id: "003",
name: "Red",
img: "https://assets.appsmith.com/widgets/default.png",
img: "http://host.docker.internal:4200/clouddefaultImage.png",
}]}}`,
);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,32 +8,32 @@ const data = [
{
id: "001",
name: "Blue",
img: "https://assets.appsmith.com/widgets/default.png",
img: "http://host.docker.internal:4200/clouddefaultImage.png",
},
{
id: "002",
name: "Green",
img: "https://assets.appsmith.com/widgets/default.png",
img: "http://host.docker.internal:4200/clouddefaultImage.png",
},
{
id: "003",
name: "Red",
img: "https://assets.appsmith.com/widgets/default.png",
img: "http://host.docker.internal:4200/clouddefaultImage.png",
},
{
id: "004",
name: "Yellow",
img: "https://assets.appsmith.com/widgets/default.png",
img: "http://host.docker.internal:4200/clouddefaultImage.png",
},
{
id: "005",
name: "Orange",
img: "https://assets.appsmith.com/widgets/default.png",
img: "http://host.docker.internal:4200/clouddefaultImage.png",
},
{
id: "006",
name: "Indigo",
img: "https://assets.appsmith.com/widgets/default.png",
img: "http://host.docker.internal:4200/clouddefaultImage.png",
},
];

Expand Down Expand Up @@ -105,7 +105,7 @@ describe(
const data = JSON.parse(val.text());
const triggeredItemView = {
Image1: {
image: "https://assets.appsmith.com/widgets/default.png",
image: "http://host.docker.internal:4200/clouddefaultImage.png",
isVisible: true,
},
Text1: {
Expand Down Expand Up @@ -137,7 +137,7 @@ describe(
const data = JSON.parse(val.text());
const SelectedRow = {
Image1: {
image: "https://assets.appsmith.com/widgets/default.png",
image: "http://host.docker.internal:4200/clouddefaultImage.png",
isVisible: true,
},
Text1: {
Expand Down Expand Up @@ -198,7 +198,7 @@ describe(
const data = JSON.parse(val.text());
const triggeredItemView = {
Image1: {
image: "https://assets.appsmith.com/widgets/default.png",
image: "http://host.docker.internal:4200/clouddefaultImage.png",
isVisible: true,
},
Text1: {
Expand Down Expand Up @@ -230,7 +230,7 @@ describe(
const data = JSON.parse(val.text());
const selectedItemView = {
Image1: {
image: "https://assets.appsmith.com/widgets/default.png",
image: "http://host.docker.internal:4200/clouddefaultImage.png",
isVisible: true,
},
Text1: {
Expand Down Expand Up @@ -313,7 +313,7 @@ describe(
const data = JSON.parse(val.text());
const triggeredItemView = {
Image1: {
image: "https://assets.appsmith.com/widgets/default.png",
image: "http://host.docker.internal:4200/clouddefaultImage.png",
isVisible: true,
},
Text1: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,7 @@ describe(

it("3. Column Detail - Edit column name and validate test for computed value based on column type selected (image, button , url)", function () {
// Changing Column data type from "Date" to "Image"
const imageVal =
"https://images.pexels.com/photos/736230/pexels-photo-736230.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500";
const imageVal = "http://host.docker.internal:4200/453-200x300.jpg";

cy.changeColumnType("Image", false);
// "Moement "date" to "Image"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -195,8 +195,7 @@ describe(
});

// Changing Column data type from "Date" to "Image"
const imageVal =
"https://images.pexels.com/photos/736230/pexels-photo-736230.jpeg?auto=compress&cs=tinysrgb&dpr=1&w=500";
const imageVal = "http://host.docker.internal:4200/453-200x300.jpg";

cy.changeColumnType("Image");
// "Moement "date" to "Image"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ describe(
propPane.ToggleJSMode("onOptionChange", true);
propPane.UpdatePropertyFieldValue(
"onOptionChange",
`{{download('https://assets.codepen.io/3/kiwi.svg', 'kiwi.svg', 'image/svg+xml').then(() => {
`{{download('http://host.docker.internal:4200/kiwi.svg', 'kiwi.svg', 'image/svg+xml').then(() => {
showAlert('Download Success', '');
});}}`,
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ describe(
//Check for Non-video url
propPane.TypeTextIntoField(
"URL",
"https://www.pexels.com/photo/closeup-photo-of-brown-brick-wall-1227511/",
"http://host.docker.internal:4200/453-200x300.jpg/",
);
deployMode.DeployApp(locators._widgetInDeployed(draggableWidgets.VIDEO));
agHelper.GetElement(widgetLocators.video).then(($video) => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ describe(
"Block Action Execution when no field is present",
{ tags: ["@tag.Datasource"] },
() => {
const url = "https://www.google.com";
const url = "https://www.appsmith.com/";
it("1. Ensure API Run button is disabled when no url is present", () => {
apiPage.CreateApi("FirstAPI", "GET");
apiPage.AssertRunButtonDisability(true);
Expand Down
Loading