Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ $ SOLIDITY_COVERAGE=true npx hardhat coverage
## Command Options
| Option <img width=200/> | Example <img width=750/>| Description <img width=1000/> |
|--------------|------------------------------------|--------------------------------|
| testfiles | `--testfiles "test/registry/*.ts"` | Test file(s) to run. (Globs must be enclosed by quotes and use [globby matching patterns][38])|
| testfiles | `--testfiles "test/registry/*.ts"` | Test file(s) to run. (Globs must be enclosed by quotes and use [glob matching patterns][38])|
| sources | `--sources myFolder` or `--sources myFile.sol` | Path to *single* folder or file to target for coverage. Path is relative to Hardhat's `paths.sources` (usually `contracts/`) |
| solcoverjs | `--solcoverjs ./../.solcover.js` | Relative path from working directory to config. Useful for monorepo packages that share settings. (Path must be "./" prefixed) |
| matrix | `--matrix` | Generate a JSON object that maps which mocha tests hit which lines of code. (Useful as an input for some fuzzing, mutation testing and fault-localization algorithms.) [More...][39]|
Expand Down Expand Up @@ -198,7 +198,7 @@ $ yarn
[35]: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/e5fbbda9bac49039847a7ed20c1d966766ecc64a/scripts/coverage.js
[36]: https://hardhat.org/
[37]: https://github.com/sc-forks/solidity-coverage/blob/master/HARDHAT_README.md
[38]: https://github.com/sindresorhus/globby#globbing-patterns
[38]: https://github.com/isaacs/node-glob#glob-primer
[39]: https://github.com/sc-forks/solidity-coverage/blob/master/docs/advanced.md#generating-a-test-matrix
[1001]: https://docs.soliditylang.org/en/v0.8.0/using-the-compiler.html#input-description
[1002]: https://github.com/sc-forks/solidity-coverage/blob/master/docs/faq.md#running-out-of-stack
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"fs-extra": "^8.1.0",
"ghost-testrpc": "^0.0.2",
"global-modules": "^2.0.0",
"globby": "^10.0.1",
"glob": "^10.4.5",
"jsonschema": "^1.2.4",
"lodash": "^4.17.21",
"mocha": "^10.2.0",
Expand Down
4 changes: 2 additions & 2 deletions plugins/resources/nomiclabs.utils.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const shell = require('shelljs');
const globby = require('globby');
const { globSync } = require('glob');
const pluginUtils = require("./plugin.utils");
const path = require('path');
const DataCollector = require("./../../lib/collector")
Expand All @@ -16,7 +16,7 @@ const util = require('util')
* @return {String[]} list of files to pass to mocha
*/
function getTestFilePaths(files){
const target = globby.sync([files])
const target = globSync(files)

// Hardhat supports js & ts
const testregex = /.*\.(js|ts)$/;
Expand Down
Loading