Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

assert-dir-equal

ianstormtaylor633MIT1.1.0

Assert that the contents of two directories are equal.

readme

assert-dir-equal

Assert that the contents of two directories are equal.

Installation

$ npm install assert-dir-equal

Example

var assert = require('assert-dir-equal');

// doesn't throw
assert('path/to/actual', 'path/to/expected');

// throws
assert('path/to/actual', 'path/to/not-identical');

Files starting with a dot are ignored by default, so they do not contribute to the equality check. This can be altered with filter option:

// check *all* files, including hidden ones
assert('path/to/actual', 'path/to/expected', {filter: () => true});

License

MIT

changelog

1.1.0 - September 6, 2017

  • add filter option

1.0.1 - March 9, 2013

  • add npmignore

1.0.0 - March 9, 2013

  • fix ordering of actual and expected

0.1.0 - February 5, 2013

  • fix false reporting for non-utf8 files

0.0.1 - February 4, 2013

:sparkles: