Added support for the last InteractiveHtmlBom to the tests.
Now the PCB modules are located in the footprints section of the generated data. This change is a general move from the module term to a more descriptive term `footprint`.
This commit is contained in:
parent
4a3e7faace
commit
f1c868b732
|
|
@ -38,9 +38,12 @@ def check_modules(ctx, fname, expected):
|
|||
assert m, text
|
||||
lz = LZString()
|
||||
js = lz.decompressFromBase64(m.group(1))
|
||||
# with open('/tmp/dump', 'wt') as f:
|
||||
# f.write(js)
|
||||
data = json.loads(js)
|
||||
skipped = data['bom']['skipped']
|
||||
modules = [m['ref'] for m in data['modules']]
|
||||
footprints_name = 'modules' if 'modules' in data else 'footprints'
|
||||
modules = [m['ref'] for m in data[footprints_name]]
|
||||
assert len(modules)-len(skipped) == len(expected)
|
||||
logging.debug("{} components OK".format(len(expected)))
|
||||
for m in expected:
|
||||
|
|
|
|||
Loading…
Reference in New Issue