Improve error messages for PostCSS etc.

Fixes #9730
This commit is contained in:
Bjørn Erik Pedersen
2023-07-17 19:15:48 +02:00
parent c406fd3a0e
commit 387c5f60f9
7 changed files with 61 additions and 7 deletions

View File

@@ -168,6 +168,25 @@ func TestTransformPostCSSError(t *testing.T) {
}
func TestTransformPostCSSNotInstalledError(t *testing.T) {
if !htesting.IsCI() {
t.Skip("Skip long running test when running locally")
}
c := qt.New(t)
s, err := hugolib.NewIntegrationTestBuilder(
hugolib.IntegrationTestConfig{
T: c,
NeedsOsFS: true,
TxtarString: postCSSIntegrationTestFiles,
}).BuildE()
s.AssertIsFileError(err)
c.Assert(err.Error(), qt.Contains, `binary with name "npx" not found`)
}
// #9895
func TestTransformPostCSSImportError(t *testing.T) {
if !htesting.IsCI() {