UNPKG

rerumaccusamus

Version:

The meta-framework suite designed from scratch for frontend-focused modern web development.

21 lines (18 loc) 561 B
import path from 'path'; import { spawnSync } from 'child_process'; const kPackageDir = path.resolve(__dirname, '..'); describe('jsnext:source', () => { test('process exit status is 0', () => { const { status, stdout, stderr } = spawnSync( process.execPath, ['--conditions=jsnext:source', '-r', 'btsm', 'src/cli.ts'], { cwd: kPackageDir, encoding: 'utf-8', }, ); expect(stdout).toBe(''); expect(stderr.startsWith('Usage: modern <command> [options]')).toBe(true); expect(status).toBe(1); }); });