Add initial test files from lodash v4. (#4172)

* Install test dependencies.

* Add initial test files.

These files were created using a simplistic AST manipulator using `recast` to
preserve formatting. There's bound to be a huge chunk of errors, but this serves
as a good start. QUnit was replaced with Mocha, with ES2015 imports running via
`esm`.

As far as possible, QUnit-specific syntax has been replaced with Mocha's
`describe` and `it`, while the native Node.js `assert` module is used for
assertions. Files in the `test` directory ending in `.test.js` will be treated
as test files.

* Add initial passing files to test run.
This commit is contained in:
Benjamin Tan
2019-02-13 01:11:32 +08:00
committed by John-David Dalton
parent 7606ea3e25
commit d5ef31929a
311 changed files with 22361 additions and 0 deletions

View File

@@ -23,6 +23,7 @@
"test": "npm run test:main && npm run test:fp",
"test:doc": "markdown-doctest doc/*.md",
"test:fp": "node test/test-fp",
"test:wip": "mocha -r esm test/*.test.js",
"test:main": "node test/test",
"validate": "npm run style && npm run test"
},
@@ -39,6 +40,7 @@
"ecstatic": "^2.1.0",
"eslint": "^3.15.0",
"eslint-plugin-import": "^2.14.0",
"esm": "^3.1.3",
"fs-extra": "~1.0.0",
"glob": "^7.1.1",
"istanbul": "0.4.5",
@@ -46,6 +48,7 @@
"lodash": "4.17.11",
"lodash-doc-globals": "^0.1.1",
"markdown-doctest": "^0.9.1",
"mocha": "^5.2.0",
"optional-dev-dependency": "^2.0.0",
"platform": "^1.3.3",
"qunit-extras": "^3.0.0",