summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTristan Van Berkom <tristan.vanberkom@codethink.co.uk>2018-01-02 17:34:29 +0900
committerTristan Van Berkom <tristan.vanberkom@codethink.co.uk>2018-01-02 17:38:55 +0900
commited9a94a4c8a524c6fe41397ac490b8b0a747ba90 (patch)
tree417a91a549e3c9174ddb92452da7536e98df719c
parent75c0920744f874cd41797a1b1d2581bc30355a89 (diff)
downloadbuildstream-ed9a94a4c8a524c6fe41397ac490b8b0a747ba90.tar.gz
plugins/sources/local.py: pragma nocover on unreachable code
The local plugin is always Consistency.CACHED, this means that fetch(), set_ref() and get_ref() methods will never be called. Instead of omitting them, just "pragma: nocover" on the `pass` statements, making our coverage report more realistic.
-rw-r--r--buildstream/plugins/sources/local.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/buildstream/plugins/sources/local.py b/buildstream/plugins/sources/local.py
index e2a769e1c..830df873f 100644
--- a/buildstream/plugins/sources/local.py
+++ b/buildstream/plugins/sources/local.py
@@ -77,14 +77,14 @@ class LocalSource(Source):
# We dont have a ref, we're a local file...
def get_ref(self):
- return None
+ return None # pragma: nocover
def set_ref(self, ref, node):
- pass
+ pass # pragma: nocover
def fetch(self):
# Nothing to do here for a local source
- pass
+ pass # pragma: nocover
def stage(self, directory):