fluid-project / fluid-lint-all

Consolidated linting logic free from any particular build technology
BSD 3-Clause "New" or "Revised" License
0 stars 5 forks source link

GH-39: Fixed empty "checked" and "valid" file counts for stylelint check (resolves #39). #42

Closed the-t-in-rtf closed 3 years ago

the-t-in-rtf commented 3 years ago

See #39 for details. The stylelintcheck was not reporting either valid or checked files correctly.

@greatislander, I have a fix for this in the dev release of 1.1.4-dev.20210604T111117Z.fa5f34f.GH-39.

the-t-in-rtf commented 3 years ago

To verify this, I used:

npm run lint -- --configFile .lintallrc-no-excludes.json --checks=stylelint

That will fail with linting errors in the "bad" CSS test fixtures we exclude from the project's default configuration.

The total was off before the fix, it reported (0/4), i.e. only invalid files were reported as checked, and none were reported as valid. With the fix proposed here, the total is correct, i.e. (4/8), which matches our structure (4 good files, 4 bad).

the-t-in-rtf commented 3 years ago

Thanks for picking up on that. I was trying to avoid hard-coding a count of good/bad files as it makes it brittle when you add files to test different things. Seems like it's time to harden that up and check the totals more closely. I'll update the tests and fix the double-counting.

the-t-in-rtf commented 3 years ago

@greatislander, I added tests for the totals and fixed the issue you reported and a few variations that were lying in wait for us. I cut 1.1.4-dev.20210608T143815Z.60f81b1.GH-39 for you to try out, hopefully that will work for you.