MCPcopy Create free account
hub / github.com/pyinvoke/invoke / invalid_path

Method invalid_path

tests/collection.py:722–730  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

720 assert collection.subcollection_from_path("build.docs") is docs
721
722 def invalid_path(self):
723 # This is really just testing Lexicon/dict behavior but w/e, good
724 # to be explicit, esp if we ever want this to become Exit or
725 # another custom exception. (For now most/all callers manually
726 # catch KeyError and raise Exit just to keep most Exit use high up
727 # in the stack...)
728 with raises(KeyError):
729 collection = Collection.from_module(load("tree"))
730 collection.subcollection_from_path("lol.whatever.man")
731
732 class serialized:
733 def empty_collection(self):

Callers

nothing calls this directly

Calls 3

loadFunction · 0.90
from_moduleMethod · 0.80

Tested by

no test coverage detected