Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Rule: no-invalid-names #203

Open
bmish opened this issue Sep 15, 2021 · 1 comment · May be fixed by #298
Open

New Rule: no-invalid-names #203

bmish opened this issue Sep 15, 2021 · 1 comment · May be fixed by #298

Comments

@bmish
Copy link
Collaborator

bmish commented Sep 15, 2021

Disallow unwanted module/test string names.

  • No leading/trailing spaces (autofixable)
  • No empty strings
  • No missing name (ava/test-title)
  • No non-string values (numbers, objects, etc)
  • No strings starting/ending in qunit delimiters (> or :)
  • We could also allow a regexp pattern option to be passed to this rule defining the required format (ava/test-title-format)

A few disallowed examples:

module(' Foo Bar @unit  ', function () {});
test(' it does foo ', function () {});

Related: qunit/no-identical-names

@platinumazure
Copy link
Owner

Working on this.

@bmish bmish linked a pull request Jan 3, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants