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

add more rules to dangerfile #1703

Merged
merged 4 commits into from
May 30, 2018
Merged

add more rules to dangerfile #1703

merged 4 commits into from
May 30, 2018

Conversation

chris48s
Copy link
Member

@shields-ci
Copy link

Messages
📖

✨ Thanks for your contribution to Shields, @chris48s!

Generated by 🚫 dangerJS

@chris48s chris48s added the developer-experience Dev tooling, test framework, and CI label May 26, 2018
});

all_files.forEach(function(file) {
if (/^services\/.+\/.+\.js$/.test(file) && file.endsWith('.js') && !file.endsWith('.tester.js')) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You should be able to get away with just using this regex:

if (/^services\/.+\/[^\.]+(?:(?!\.tester))\.js$/.test(file)) {

But the way you have it currently is more self explanatory.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think in this case the longer expression is more readable

Copy link
Member

@platan platan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can merge it and then prepare a PR which will test if rules works as expected.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
developer-experience Dev tooling, test framework, and CI
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants