File tree Expand file tree Collapse file tree 3 files changed +13
-1
lines changed Expand file tree Collapse file tree 3 files changed +13
-1
lines changed Original file line number Diff line number Diff line change 25
25
"prepack" : " scripts/prepack.sh" ,
26
26
"generate" : " scripts/generate/run.js" ,
27
27
"version" : " scripts/release/version.sh" ,
28
- "test" : " hardhat test" ,
28
+ "test" : " scripts/set-max-old-space-size.sh && hardhat test" ,
29
29
"test:generation" : " scripts/checks/generation.sh" ,
30
30
"test:inheritance" : " scripts/checks/inheritance-ordering.js artifacts/build-info/*" ,
31
31
"test:pragma" : " scripts/checks/pragma-consistency.js artifacts/build-info/*" ,
Original file line number Diff line number Diff line change @@ -5,6 +5,8 @@ set -euo pipefail
5
5
export COVERAGE=true
6
6
export FOUNDRY_FUZZ_RUNS=10
7
7
8
+ scripts/set-max-old-space-size.sh
9
+
8
10
# Hardhat coverage
9
11
hardhat coverage
10
12
Original file line number Diff line number Diff line change
1
+ #! /usr/bin/env bash
2
+
3
+ # This script sets the node `--max-old-space-size` to 8192 if it is not set already.
4
+ # All existing `NODE_OPTIONS` are retained as is.
5
+
6
+ export NODE_OPTIONS=" ${NODE_OPTIONS:- } "
7
+
8
+ if [[ $NODE_OPTIONS != * " --max-old-space-size" * ]]; then
9
+ export NODE_OPTIONS=" ${NODE_OPTIONS} --max-old-space-size=8192"
10
+ fi
You can’t perform that action at this time.
0 commit comments