feat: publish CodexPi contest snapshot
Some checks are pending
Qualité / tests (push) Waiting to run

This commit is contained in:
CodexPi
2026-11-14 20:23:59 +01:00
commit 995b17a6e2
295 changed files with 36803 additions and 0 deletions

View File

@@ -0,0 +1,20 @@
import assert from 'node:assert/strict'
import test from 'node:test'
import { parseCommandLine } from '../src/commandLine.ts'
test('quoted arguments retain their spaces',()=>{
assert.deepEqual(parseCommandLine('pytest "tests/my feature.py" -k \'works here\''),['pytest','tests/my feature.py','-k','works here'])
})
test('escaped spaces and empty quoted arguments are retained',()=>{
assert.deepEqual(parseCommandLine('tool one\\ two ""'),['tool','one two',''])
})
test('windows paths are not damaged by parsing',()=>{
assert.deepEqual(parseCommandLine('py "C:\\Mes Tests\\test.py"'),['py','C:\\Mes Tests\\test.py'])
})
test('an unclosed quote is rejected',()=>{
assert.throws(()=>parseCommandLine('pytest "tests/file.py'),/Guillemet non fermé/)
})