Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit6f67dbd

Browse files
authored
test: Usedeep.eq for comparing objects (#34513)
The JSON string comparison is flaky because it depends on the order ofkeys in serialized objects. We actually don't care for the order thekeys are serialized, just that the keys and values are as we want.This PR should fix that.[Slackconversation](https://theappsmith.slack.com/archives/C0134BAVDB4/p1719409620659339)./test table<!-- This is an auto-generated comment: Cypress test results -->> [!TIP]> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉> Workflow run:<https://github.com/appsmithorg/appsmith/actions/runs/9681276909>> Commit:3fa1746> <ahref="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=9681276909&attempt=1"target="_blank">Cypress dashboard</a>.> Tags: `@tag.Table`<!-- end of auto-generated comment: Cypress test results -->
1 parent57f86de commit6f67dbd

File tree

1 file changed

+22
-14
lines changed

1 file changed

+22
-14
lines changed

‎app/client/cypress/e2e/Regression/ClientSide/Widgets/TableV2/Date_column_editing_1_spec.ts‎

Lines changed: 22 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -60,20 +60,28 @@ describe(
6060
);
6161
agHelper.AssertElementAbsence(table._dateInputPopover);
6262
agHelper.AssertElementAbsence(table._editCellEditor);
63-
agHelper
64-
.GetText(locators._textWidget,"text",0)
65-
.then(($textData)=>
66-
expect($textData).to.eq(
67-
`{"revenue":42600000,"imdb_id":"tt3228774","release_date":"2021-05-17"}`,
68-
),
69-
);
70-
agHelper
71-
.GetText(locators._textWidget,"text",1)
72-
.then(($textData)=>
73-
expect($textData).to.eq(
74-
`[{"index":0,"updatedFields":{"release_date":"2021-05-17"},"allFields":{"revenue":42600000,"imdb_id":"tt3228774","release_date":"2021-05-17"}}]`,
75-
),
76-
);
63+
agHelper.GetText(locators._textWidget,"text",0).then(($textData)=>
64+
expect(JSON.parse($textDataasstring)).to.deep.eq({
65+
revenue:42600000,
66+
imdb_id:"tt3228774",
67+
release_date:"2021-05-17",
68+
}),
69+
);
70+
agHelper.GetText(locators._textWidget,"text",1).then(($textData)=>
71+
expect(JSON.parse($textDataasstring)).to.deep.eq([
72+
{
73+
index:0,
74+
updatedFields:{
75+
release_date:"2021-05-17",
76+
},
77+
allFields:{
78+
revenue:42600000,
79+
imdb_id:"tt3228774",
80+
release_date:"2021-05-17",
81+
},
82+
},
83+
]),
84+
);
7785
agHelper
7886
.GetText(locators._textWidget,"text",2)
7987
.then(($textData)=>expect($textData).to.eq("[0]"));

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp