diff --git a/tests/board_samples/kibom-test.sch b/tests/board_samples/kibom-test.sch index 5b0bacbb..d5c8c661 100644 --- a/tests/board_samples/kibom-test.sch +++ b/tests/board_samples/kibom-test.sch @@ -89,7 +89,7 @@ P 2500 3100 F 0 "R7" V 2580 3100 50 0000 C CNN F 1 "4700" V 2500 3100 50 0000 C CNN F 2 "Resistor_SMD:R_0805_2012Metric" V 2430 3100 50 0001 C CNN -F 3 "~" H 2500 3100 50 0001 C CNN +F 3 "http://www.google.com/" H 2500 3100 50 0001 C CNN F 4 "DNC" V 2500 3100 50 0001 C CNN "Config" 1 2500 3100 1 0 0 -1 diff --git a/tests/test_plot/test_int_bom.py b/tests/test_plot/test_int_bom.py index 33dfb9ec..53de48af 100644 --- a/tests/test_plot/test_int_bom.py +++ b/tests/test_plot/test_int_bom.py @@ -61,12 +61,14 @@ REF_COLUMN_NAME_R = 'Referencias' QTY_COLUMN_NAME = 'Quantity Per PCB' COMP_COLUMN_NAME = 'Row' COMP_COLUMN_NAME_R = 'Renglón' +DATASHEET_COLUMN_NAME = 'Datasheet' KIBOM_TEST_HEAD = [COMP_COLUMN_NAME, 'Description', 'Part', REF_COLUMN_NAME, 'Value', 'Footprint', QTY_COLUMN_NAME, - 'Datasheet', 'Config'] + DATASHEET_COLUMN_NAME, 'Config'] KIBOM_TEST_HEAD_TOL = [c for c in KIBOM_TEST_HEAD] KIBOM_TEST_HEAD_TOL.insert(-1, 'Tolerance') KIBOM_RENAME_HEAD = [COMP_COLUMN_NAME_R, REF_COLUMN_NAME_R, 'Componente', 'Valor', 'Código Digi-Key', 'Cantidad por PCB'] -CONN_HEAD = [COMP_COLUMN_NAME, 'Description', 'Part', REF_COLUMN_NAME, 'Value', 'Footprint', QTY_COLUMN_NAME, 'Datasheet'] +CONN_HEAD = [COMP_COLUMN_NAME, 'Description', 'Part', REF_COLUMN_NAME, 'Value', 'Footprint', QTY_COLUMN_NAME, + DATASHEET_COLUMN_NAME] KIBOM_TEST_COMPONENTS = ['C1', 'C2', 'C3', 'C4', 'R1', 'R2', 'R3', 'R4', 'R5', 'R7', 'R8', 'R9', 'R10'] KIBOM_TEST_COMPONENTS_ALT = ['C1-C4', 'R9-R10', 'R7', 'R8', 'R1-R5'] KIBOM_TEST_COMPONENTS_ALT2 = ['C1-C4', 'R9-R10', 'R7', 'R8', 'R1-R2', 'R4-R5', 'R3'] @@ -111,11 +113,14 @@ def check_kibom_test_netlist(rows, ref_column, groups, exclude, comps): logging.debug("list of components OK") -def check_dnc(rows, comp, ref, qty): +def check_dnc(rows, comp, ref, qty, datasheet=None): for row in rows: if row[ref].find(comp) != -1: assert row[qty] == '1 (DNC)' logging.debug(comp + " is DNC OK") + if datasheet is not None: + assert row[datasheet].startswith('