Skip to content

Commit

Permalink
Remove use of rsyncdir
Browse files Browse the repository at this point in the history
Fixes: #557
  • Loading branch information
ssbarnea committed Oct 26, 2022
1 parent 297965e commit 0242835
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion docs/xdist.rst
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ Again but spread over different hosts and different directories::
pytest --cov=myproj --dist load
--tx ssh=memedough@host1//chdir=testenv1
--tx ssh=memedough@host2//chdir=/tmp/testenv2//python=/tmp/env1/bin/python
--rsyncdir myproj --rsyncdir tests --rsync examples
--rsync examples
tests/

Shows a terminal report::
Expand Down
4 changes: 3 additions & 1 deletion src/pytest_cov/engine.py
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,9 @@ def start(self):

# Ensure coverage rc file rsynced if appropriate.
if self.cov_config and os.path.exists(self.cov_config):
self.config.option.rsyncdir.append(self.cov_config)
# rsyncdir is going away in pytest-xdist 4.0, already deprecated
if hasattr(self.config.option, 'rsyncdir'):
self.config.option.rsyncdir.append(self.cov_config)

self.cov = coverage.Coverage(source=self.cov_source,
branch=self.cov_branch,
Expand Down

0 comments on commit 0242835

Please sign in to comment.