Skip to content

Commit

Permalink
fix: Simplify TEST_EXTENSIONS null/undefined check (#84)
Browse files Browse the repository at this point in the history
  • Loading branch information
meyfa committed Sep 17, 2023
1 parent 1e1dd4f commit aa92fcb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/index.ts
Expand Up @@ -6,7 +6,7 @@ import { resolveTestPaths } from './resolution.js'
const DEFAULT_TEST_EXTENSIONS = ['.js', '.mjs', '.cjs', '.ts', '.mts', '.cts']

export function getTestExtensions (): string[] {
if (typeof process.env.TEST_EXTENSIONS !== 'undefined' && process.env.TEST_EXTENSIONS !== null) {
if (process.env.TEST_EXTENSIONS != null) {
return process.env.TEST_EXTENSIONS.split(',').map(e => e.trim())
}
return DEFAULT_TEST_EXTENSIONS
Expand Down

0 comments on commit aa92fcb

Please sign in to comment.