Method
__init__
(
self,
fspath: Optional[LEGACY_PATH],
parent: nodes.Collector,
# NOTE: following args are unused:
config=None,
session=None,
nodeid=None,
path=Optional[Path],
)
Source from the content-addressed store, hash-verified
| 642 | |
| 643 | class Package(Module): |
| 644 | def __init__( |
| 645 | self, |
| 646 | fspath: Optional[LEGACY_PATH], |
| 647 | parent: nodes.Collector, |
| 648 | # NOTE: following args are unused: |
| 649 | config=None, |
| 650 | session=None, |
| 651 | nodeid=None, |
| 652 | path=Optional[Path], |
| 653 | ) -> None: |
| 654 | # NOTE: Could be just the following, but kept as-is for compat. |
| 655 | # nodes.FSCollector.__init__(self, fspath, parent=parent) |
| 656 | session = parent.session |
| 657 | nodes.FSCollector.__init__( |
| 658 | self, |
| 659 | fspath=fspath, |
| 660 | path=path, |
| 661 | parent=parent, |
| 662 | config=config, |
| 663 | session=session, |
| 664 | nodeid=nodeid, |
| 665 | ) |
| 666 | self.name = self.path.parent.name |
| 667 | |
| 668 | def setup(self) -> None: |
| 669 | # Not using fixtures to call setup_module here because autouse fixtures |
Tested by
no test coverage detected