"npm test" fails, complaining of "No ESLint configuration found"
Closed, ResolvedPublic

Description

Since rMWc0fb8a883633: build: Replace jscs+jshint with eslint, running npm test on core fails complaining that "No ESLint configuration found", even though the eslint configuration file is present.

It turns out that this occurs when extensions are symlinked from extensions/ and the symlinked extensions have a .js file (e.g. Gruntfile.js) and package.json in their root directory, thanks to grunt's file globbing.

The ** item in grunt's globbing matches symlinks but does not follow them. Thus, when processing **/*.js, the ** matches the symlink extensions/AbuseFilter and it goes on to look for extensions/AbuseFilter/*.js. But when grunt is processing !extensions/** to try to exclude extensions, it sees extensions/AbuseFilter as a match but does not find any files behind that symlink to exclude them.

A quick fix would be to have the exclusion more closely match the inclusion: !extensions/**/*.js would find the same JS files behind the symlink that **/*.js found and so would properly exclude them.