Skip to content

Commit fb8b935

Browse files
committed
check layers
1 parent aa19996 commit fb8b935

1 file changed

Lines changed: 40 additions & 1 deletion

File tree

.evergreen/run-tests.sh

Lines changed: 40 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,4 +58,43 @@ export MONGODB_URI=${MONGODB_URI}
5858
export LOAD_BALANCER=${LOAD_BALANCER}
5959
export TEST_CSFLE=${TEST_CSFLE}
6060
export COMPRESSOR=${COMPRESSOR}
61-
npm run check:integration-coverage
61+
62+
# OOM exit code investigation - run through each layer and log exit codes
63+
set +e
64+
65+
OOM_TEST="test/integration/oom.test.ts"
66+
67+
echo "========================================="
68+
echo "Layer 1: direct mocha"
69+
echo "========================================="
70+
npx mocha --config test/mocha_mongodb.js "$OOM_TEST"
71+
echo "EXIT CODE: $?"
72+
73+
echo "========================================="
74+
echo "Layer 2: npm run check:test (npm -> mocha)"
75+
echo "========================================="
76+
npm run check:test -- "$OOM_TEST"
77+
echo "EXIT CODE: $?"
78+
79+
echo "========================================="
80+
echo "Layer 3: nyc mocha (nyc -> mocha, no npm)"
81+
echo "========================================="
82+
npx nyc mocha --config test/mocha_mongodb.js "$OOM_TEST"
83+
echo "EXIT CODE: $?"
84+
85+
echo "========================================="
86+
echo "Layer 4: nyc npm run check:test (nyc -> npm -> mocha)"
87+
echo "========================================="
88+
npx nyc npm run check:test -- "$OOM_TEST"
89+
echo "EXIT CODE: $?"
90+
91+
echo "========================================="
92+
echo "Layer 5: npm run check:integration-coverage (npm -> nyc -> npm -> mocha)"
93+
echo "========================================="
94+
npm run check:integration-coverage -- "$OOM_TEST"
95+
echo "EXIT CODE: $?"
96+
97+
echo "========================================="
98+
echo "DONE - any EXIT CODE of 0 above means that layer swallows the OOM"
99+
echo "========================================="
100+
exit 1

0 commit comments

Comments
 (0)