mozilla / addons-linter

🔍 Firefox Add-ons linter, written in JavaScript. 👁
Mozilla Public License 2.0
314 stars 144 forks source link

Add test to make sure a webext provided eslintrc can't override anything. #1141

Open EnTeQuAk opened 7 years ago

EnTeQuAk commented 7 years ago

See https://github.com/mozilla/addons-linter/pull/1140#discussion_r102709503

┆Issue is synchronized with this Jira Task

wagnerand commented 7 years ago

@EnTeQuAk could you please add some more information what this is about and what needs to be done so we can triage it?

EnTeQuAk commented 7 years ago

This is about adding a test that adds a new webext fixture with a .eslintrc that tries to override our default values set by our JavaScriptScanner (https://github.com/mozilla/addons-linter/blob/master/src/scanners/javascript.js#L38-L58) by using all means necessary given by http://eslint.org/docs/user-guide/configuring

It should not be possible to override any of these values (most importantly to check rules isn't changable or files aren't ignored).

kamsuri commented 7 years ago

Hi @EnTeQuAk! Can i take this up?

muffinresearch commented 6 years ago

@kamsuri if you still have time to look at this we'd welcome a contribution.

stale[bot] commented 3 years ago

This issue has been automatically marked as stale because it has not had recent activity. If you think this bug should stay open, please comment on the issue with further details. Thank you for your contributions.

wagnerand commented 3 years ago

@rpl is this related to https://github.com/mozilla/addons-linter/issues/3389?

rpl commented 3 years ago

@rpl is this related to #3389?

that was about the .eslintignore file (and for that we do have an integration test that covers it), this is about the eslintrc file, and so the test added in #3389 do not cover this one at the moment.

I took a quick look and it seems that we do not have any other test that covers this, but we do still configure eslint to ignore the eslintrc file here, and so this issue seems to be still valid.

To fix this issue we could:

stale[bot] commented 3 years ago

This issue has been automatically marked as stale because it has not had recent activity. If you think this bug should stay open, please comment on the issue with further details. Thank you for your contributions.