testdouble / teenytest

A very simple, zero-config test runner for Node.js
MIT License
96 stars 14 forks source link

Glob missing files with hyphens #38

Closed amiel closed 6 years ago

amiel commented 6 years ago

I'm not sure if this is an issue with teenytest or the underlying globbing library and I'm not in a position to easily troubleshoot the root cause so I thought I would start with an issue here.

Issue

Using a glob expression like test/**/*.test.js did not find and run a file that included a hyphen (-) in the name. It did run a test file with a name that was identical except with an underscore instead of a hyphen.

Example

I've created an example at https://github.com/amiel/teenytest-glob-issue. Please see the README.md there for instructions and descriptions of expected and actual behavior.

searls commented 6 years ago

No problem, you just need to quote the glob as shown here: https://github.com/amiel/teenytest-glob-issue/pull/1

amiel commented 6 years ago

@searls Thanks! I'll leave my example so that anyone with a similar issue can find your solution.