From 5e818edc2f41868855adcbdbe14c69ef767166de Mon Sep 17 00:00:00 2001 From: Andrey Goncharov Date: Wed, 17 Aug 2022 04:37:52 -0700 Subject: [PATCH] Expose text report for unit test code coverage Summary: At the request of msys Reviewed By: lblasa Differential Revision: D38740940 fbshipit-source-id: 25722144037ce404ef7572e9553037e7344c6955 --- desktop/jest.config.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/desktop/jest.config.js b/desktop/jest.config.js index d30a43c44..926b4370f 100644 --- a/desktop/jest.config.js +++ b/desktop/jest.config.js @@ -22,7 +22,12 @@ module.exports = { '^flipper-(pkg|pkg-lib|doctor|test-utils)$': '/$1/src', }, clearMocks: true, - coverageReporters: ['json-summary', 'lcov', 'html'], + coverageReporters: [ + 'json-summary', + 'lcov', + 'html', + ...(process.env.COVERAGE_TEXT === 'detailed' ? ['text'] : []), + ], testMatch: ['**/**.(node|spec).(js|jsx|ts|tsx)'], testEnvironment: 'jest-environment-jsdom-sixteen', resolver: '/jest.resolver.js',