Skip to content

Commit

Permalink
Add a test for pytest-dev#1235
Browse files Browse the repository at this point in the history
  • Loading branch information
dmerejkowsky committed Mar 1, 2016
1 parent 63b6932 commit 44b8439
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion testing/acceptance_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,18 @@ def test_chdir(self, testdir):
result = testdir.runpython(p)
assert not result.ret

def test_removing_cwd(self, testdir):
testdir.makepyfile("""
def test_deleting_cwd(tmpdir, monkeypatch):
work = tmpdir.mkdir("work")
monkeypatch.chdir(work)
work.remove()
# Actual testing here
assert False
""")
result = testdir.runpytest()
assert result.ret == EXIT_TESTSFAILED

def test_issue109_sibling_conftests_not_loaded(self, testdir):
sub1 = testdir.tmpdir.mkdir("sub1")
sub2 = testdir.tmpdir.mkdir("sub2")
Expand Down Expand Up @@ -678,4 +690,3 @@ def test_setup_function(self, testdir):
* setup *test_1*
* call *test_1*
""")

0 comments on commit 44b8439

Please sign in to comment.