summaryrefslogtreecommitdiff
path: root/tests/farm/run/run_chdir.py
blob: 5ec0b4ea0a206a403a63a3e86b5c4df8547e96c3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
# Licensed under the Apache License: http://www.apache.org/licenses/LICENSE-2.0
# For details: https://github.com/nedbat/coveragepy/blob/master/NOTICE.txt

copy("src", "out_chdir")
run("""
    coverage run chdir.py
    coverage report
    """, rundir="out_chdir", outfile="stdout.txt")
contains("out_chdir/stdout.txt",
        "Line One",
        "Line Two",
        "chdir"
        )
doesnt_contain("out_chdir/stdout.txt", "No such file or directory")
clean("out_chdir")