diff options
Diffstat (limited to 'test/test_read_schematic.py')
-rw-r--r-- | test/test_read_schematic.py | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/test/test_read_schematic.py b/test/test_read_schematic.py index 1af7002..2b269a6 100644 --- a/test/test_read_schematic.py +++ b/test/test_read_schematic.py @@ -35,7 +35,7 @@ def dump_bom(sch): def load(path): p = basedir + "/parser/" + path print("p={}".format(p)) - sch = kicad.read_schematic(p) + sch = kicad.read_schematics(p) return sch @@ -51,3 +51,14 @@ def test_sch(): sch = load("foo.sch") dump_schema(sch) dump_bom(sch) + + +def test_hierarchical(): + sch = load("hierarchical/hierarchical.sch") + dump_schema(sch) + dump_bom(sch) + assert 3 == len(sch.components) + assert 3 == len(sch.schematics) + assert sch.get_component("R101") + assert sch.get_component("C201") + assert sch.get_component("L301") |