webpack-contrib / postcss-loader

PostCSS loader for webpack
MIT License
2.86k stars 211 forks source link

test: sourcemaps with an actual plugin #680

Closed romainmenke closed 7 months ago

romainmenke commented 7 months ago

This PR contains a:

Motivation / Use-Case

PostCSS has two modes:

NoWorkResult is an optimized path that is taken if no plugins, parsers, ... are provided. The assumption here is that the user has a bad config and doesn't actually want to use PostCSS.

LazyResult is PostCSS actually doing things.

The sourcemaps generated for both modes are radically different.

This changes adds a noop plugin to trigger the LazyResult mode.

Breaking Changes

N/A

Additional Info

I don't know if this might surface subtle bugs here. Main purpose is to have better test coverage.

I am trying to pinpoint the cause of this issue : https://github.com/postcss/postcss/issues/1914

linux-foundation-easycla[bot] commented 7 months ago

CLA Signed

The committers listed above are authorized under a signed CLA.

romainmenke commented 7 months ago

Changed my mind, better not to change these tests unless there is an actual issue.