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

fix(karma): fix included:false pattern being ignored #1664

Closed
wants to merge 1 commit into from

Conversation

raspo
Copy link

@raspo raspo commented Oct 27, 2015

Closes #1530

@googlebot
Copy link

Thanks for your pull request. It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

📝 Please visit https://cla.developers.google.com/ to sign.

Once you've signed, please reply here (e.g. I signed it!) and we'll verify. Thanks.


  • If you've already signed a CLA, it's possible we don't have your GitHub username or you're using a different email address. Check your existing CLA data and verify that your email is set on your git commits.
  • If you signed the CLA as a corporation, please let us know the company's name.

@raspo
Copy link
Author

raspo commented Oct 27, 2015

I signed it!

@googlebot
Copy link

CLAs look good, thanks!

@dignifiedquire
Copy link
Member

Thanks a lot, could you change the commit message to something like this: fix(file-list): ...

Also it seems there is an issue with the tests now, please make sure they pass.

@raspo
Copy link
Author

raspo commented Oct 27, 2015

@dignifiedquire I updated the commit message. Can you help me figure out what is the problem with travis? I don't get any errors when I run tests locally with grunt test.

@karmarunnerbot
Copy link
Member

the problem here is the karma.conf.js file for this test:

files: [
  'test-main.js',
  {pattern: '*.js', included: false},
],

excludes 'test-main.js' which starts karma so karma never starts so it times out. Perhaps get rid of the 'excluded' check when figuring out all of the included files? Seems a file being included should take precedence over it being excluded?

@zzo
Copy link
Contributor

zzo commented Oct 30, 2015

oh heh heh I was accidentally signed in as 'karmarunnerbot' when I made that previous comment - sorry it's me.

@raspo
Copy link
Author

raspo commented Nov 3, 2015

When defining patterns all files are included by default and when you want to exclude some you have to specify included: false. It feels to me like the excluded patterns should take priority over the included ones.
In either case, one of the two should have a higher priority and should probably be documented somewhere. Thoughts? @zzo @dignifiedquire

@zzo
Copy link
Contributor

zzo commented Nov 4, 2015

ya seems like if a file is specifically included (without using a regex) but it's being also excluded by an exclude regex the include should win in that case - at least that's how it must have been working before for that test to pass - or something like that :)

@dignifiedquire
Copy link
Member

Sorry for not responding earlier. I agree withehat @zzo says, to keep the old behaviour includes should take precendence over excludes if the pattern is more specific. I'm happy to discuss chamges to that in the future but for now we need that behaviour nack so we don't break everyones code.

@dignifiedquire
Copy link
Member

@raspo any chance you could look into finishing this?

@dignifiedquire
Copy link
Member

@raspo ping

@dignifiedquire
Copy link
Member

@raspo ping?

@dignifiedquire
Copy link
Member

Solved in another PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants