Skip to content

adding customTests leads to ENOENT: no such file or directory #39

@luksak

Description

@luksak

I keep getting an error that my customTests file doesn't exist:

[15:18:03] Starting 'modernizr'...
[15:18:03] Finished 'modernizr' after 9.83 ms

>> Explicitly including these tests:
>> touchevents

Looking for Modernizr references

>> Ready to build using these settings:
>> addTest, html5printshiv, testProp, fnBind

Building your customized Modernizr{ [Error: Error: ENOENT: no such file or directory, open '/Users/user/Sites/project/web/themes/project/node_modules/modernizr/lib/../src/test/../../../../../js/utils/modernizrVideoAutoplay.js'
In module tree:
    modernizr-init

    at Error (native)
]
  originalError: 
   { [Error: ENOENT: no such file or directory, open '/Users/user/Sites/project/web/themes/project/node_modules/modernizr/lib/../src/test/../../../../../js/utils/modernizrVideoAutoplay.js']
     errno: -2,
     code: 'ENOENT',
     syscall: 'open',
     path: '/Users/user/Sites/project/web/themes/project/node_modules/modernizr/lib/../src/test/../../../../../js/utils/modernizrVideoAutoplay.js',
     fileName: '/Users/user/Sites/project/web/themes/project/node_modules/modernizr/lib/../src/test/../../../../../js/utils/modernizrVideoAutoplay.js',
     moduleTree: [ 'modernizr-init' ] } }

There is no folder src/test inside modernizr.

Here is the relevant part in my gulpfile.js:

gulp.task('modernizr', function() {
  gulp.src('./js/*.js')
    .pipe(modernizr({
      'tests' : ['touchevents'],
      'customTests': ['./js/utils/modernizrVideoAutoplay.js']
    }))
    .pipe(gulp.dest(path.modernizr.dist))
});

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions