From 89197dad4f5f427faa7fba12971b20037ad5ba71 Mon Sep 17 00:00:00 2001 From: Trygve Laugstøl Date: Fri, 14 Jun 2019 10:40:31 +0200 Subject: split-parts-by-supplier: rename to split-bom-by-supplier. digikey-create-bom: Implementing CSV generation for Digi-Key. --- test/part/test_bom.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 test/part/test_bom.py (limited to 'test/part') diff --git a/test/part/test_bom.py b/test/part/test_bom.py new file mode 100644 index 0000000..85eb932 --- /dev/null +++ b/test/part/test_bom.py @@ -0,0 +1,12 @@ +import pytest +from ee.part.bom import join_refs + + +@pytest.mark.parametrize("inputs, output", [ + [[], ""], + [["C1"], "C1"], + [["C1", "C2"], "C1,2"], + [["C1", "C2", "C3", "C5", "C6", "C9"], "C1-3,5,6,9"], +]) +def test_basic(inputs, output): + assert output == join_refs(inputs) -- cgit v1.2.3