I’m stuck on the last stage with this test error output:
remote: [tester::#UN3] Running tests for Stage #UN3 (Redirection - Append stderr)
remote: [tester::#UN3] Running ./your_program.sh
remote: [tester::#UN3] Writing file "/tmp/quz/apple" with content "apple"
remote: [tester::#UN3] Writing file "/tmp/quz/blueberry" with content "blueberry"
remote: [tester::#UN3] Writing file "/tmp/quz/grape" with content "grape"
remote: [your-program] $ ls -1 nonexistent >> /tmp/foo/baz.md
remote: [tester::#UN3] Failed to read file ("/tmp/foo/baz.md"): open /tmp/foo/baz.md: no such file or directory
remote: [your-program] ls: nonexistent: No such file or directory
remote: [your-program] $
remote: [tester::#UN3] Assertion failed.
remote: [tester::#UN3] Test failed (try setting 'debug: true' in your codecrafters.yml to see more details)
The test run with debug: true
gives the same output as above. The same code, when i run it locally gives me the expected output:
$ ls nonexistent >> ./temp
ls: cannot access 'nonexistent': No such file or directory
$ ls -1 nonexistent >> ./temp
ls: cannot access 'nonexistent': No such file or directory
$
Is this a bug in my code or in the test? GitHub - giacomo-folli/codecrafters-shell