Skip to content

Conversation

JCQuintas
Copy link
Member

  • Enable tsx in test/regressions
  • Moved files from docs/data/visual-regression-tests/ to test/regressions/charts/
  • Enabled visual regressions for the pickers files in test/regressions/pickers/

@JCQuintas JCQuintas requested review from a team September 16, 2025 13:31
@JCQuintas JCQuintas self-assigned this Sep 16, 2025
@JCQuintas JCQuintas added type: enhancement It’s an improvement, but we can’t make up our mind whether it's a bug fix or a new feature. scope: code-infra Involves the code-infra product (https://www.notion.so/mui-org/5562c14178aa42af97bc1fa5114000cd). labels Sep 16, 2025
});
});

const pickersImports = import.meta.glob<React.ComponentType>('./pickers/**/*.{js,tsx}', {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mui/explore I suppose the files under test/regressions/pickers should be tested, but they weren't before, so I enabled it.

Let me know if you would like to keep this disabled or remove these files instead.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They were imported as is from the Core 3 years ago, never tested and just migrated when we did BCs
I'll let the @michelengelen and the customer success team decide what to do with them.
The tests are probably very outdated and not representative, but some might be valuable.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@michelengelen they don't seem to provide much right now as they are being clipped, I could fix them, but do we want to?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMHO we can skip them, if they don't provide much value anyways. I haven't touched them ever, so I am mot really sure either. Maybe it's better to start a fresh set of tests? @flaviendelangle definitely has more insights into this than I do.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's skip them then 👍

@mui-bot
Copy link

mui-bot commented Sep 16, 2025

Deploy preview: https://deploy-preview-19595--material-ui-x.netlify.app/

Bundle size report

Bundle Parsed size Gzip size
@mui/x-data-grid 0B(0.00%) 0B(0.00%)
@mui/x-data-grid-pro 0B(0.00%) 0B(0.00%)
@mui/x-data-grid-premium 0B(0.00%) 0B(0.00%)
@mui/x-charts 0B(0.00%) 0B(0.00%)
@mui/x-charts-pro 0B(0.00%) 0B(0.00%)
@mui/x-date-pickers 0B(0.00%) 0B(0.00%)
@mui/x-date-pickers-pro 0B(0.00%) 0B(0.00%)
@mui/x-tree-view 0B(0.00%) 0B(0.00%)
@mui/x-tree-view-pro 0B(0.00%) 0B(0.00%)

Details of bundle changes

Generated by 🚫 dangerJS against 0c4ab6d

});
Object.keys(chartsImports).forEach((path: string) => {
const name = path.replace('./charts/', '').replace('.js', '');
const name = path.replace('./charts/', '').replace(/\.[A-z]+$/, '');
Copy link
Member

@Janpot Janpot Sep 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggestion: extract helper to avoid duplicate extension removing logic.

// string based variant is about 2.5x faster as well
const removeExtension = (filePath) => {
  const extStart = filePath.lastIndexOf('.');
  return extStart >= 0 ? filePath.slice(0, extStart) : filePath;
};

@JCQuintas JCQuintas merged commit 4e6ee77 into mui:master Sep 18, 2025
21 checks passed
@JCQuintas JCQuintas deleted the visual-regressions-improvements branch September 18, 2025 11:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
scope: code-infra Involves the code-infra product (https://www.notion.so/mui-org/5562c14178aa42af97bc1fa5114000cd). type: enhancement It’s an improvement, but we can’t make up our mind whether it's a bug fix or a new feature.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants