Test using a File as an argument to run_command.

This commit is contained in:
Jussi Pakkanen 2020-02-04 22:59:23 +02:00
parent a3e2aa2d66
commit 302b486446
1 changed files with 6 additions and 0 deletions

View File

@ -185,6 +185,12 @@ ret = run_command(check_file, inf, outf)
if ret.returncode() != 0
error('Error running command: @0@\n@1@'.format(ret.stdout(), ret.stderr()))
endif
# Now the same, but using a File object as an argument.
inf2 = files('invalid-utf8.bin.in')[0]
ret = run_command(check_file, inf2, outf)
if ret.returncode() != 0
error('Error running command: @0@\n@1@'.format(ret.stdout(), ret.stderr()))
endif
# Test copy of a binary file
outf = configure_file(input : inf,