Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[test] Split cell/row editing tests #3618

Merged
merged 3 commits into from Jan 19, 2022
Merged

Conversation

m4theushw
Copy link
Member

Following #3219, I think it would be better to also separate the tests. Although both edit modes share a lot of things, I find easier to see them as two complete different features. Concerning testing, the editRows.DataGridPro.test.tsx file has more than 1600 LOC. It's impractical to navigate between all of tests. In this PR I propose to split them into 3 new files:

  1. cellEditing.DataGridPro.test.tsx is only to test the general functionality of the cell editing.
  2. rowEditing.DataGridPro.test.tsx is similar to above but only for row editing tests.
  3. editComponents.DataGridPro.test.tsx is meant to test the edit components provided by each column type. If one component behaves differently in editMode=row I would add its tests here.

It's not necessary to go through each file, I'm only moving the tests without changing them. I didn't automerge because I want to collect some feedback about the new structure.

@m4theushw m4theushw added the test label Jan 14, 2022
@m4theushw m4theushw self-assigned this Jan 14, 2022
@flaviendelangle
Copy link
Member

flaviendelangle commented Jan 14, 2022

A lot better that way
Could we put the orphan it at the end (move validation and control Editing describe up) in cellEditing ?

@github-actions github-actions bot added the PR: out-of-date The pull request has merge conflicts and can't be merged label Jan 17, 2022
@github-actions
Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged label Jan 17, 2022
@mui-bot
Copy link

mui-bot commented Jan 17, 2022

These are the results for the performance tests:

Test case Unit Min Max Median Mean σ
Filter 100k rows ms 141.8 303.9 224 232.36 59.257
Sort 100k rows ms 281.4 615.8 601.9 519.6 127.652
Select 100k rows ms 160.4 307.9 204.8 226.6 51.203
Deselect 100k rows ms 108.2 283.1 142.2 166.36 63.215

Generated by 🚫 dangerJS against 6f27809

@m4theushw m4theushw merged commit e83ea59 into mui:master Jan 19, 2022
@m4theushw m4theushw deleted the organize-tests branch January 19, 2022 22:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants