From 313d66c58ace41a0e21638a5d7299705606beffe Mon Sep 17 00:00:00 2001
From: "Mayr, Hannes" <hannes.mayr@stud.tu-darmstadt.de>
Date: Thu, 22 Dec 2022 15:48:48 +0100
Subject: [PATCH] Include custom IDs in unittests.

---
 plotid/tagplot.py                | 3 +++
 tests/test_tagplot_image.py      | 3 ++-
 tests/test_tagplot_matplotlib.py | 1 +
 3 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/plotid/tagplot.py b/plotid/tagplot.py
index a0a3d29..3c01d06 100644
--- a/plotid/tagplot.py
+++ b/plotid/tagplot.py
@@ -39,6 +39,9 @@ def tagplot(
 
     Other Parameters
     ----------------
+    figure_ids: list of str, optional
+        IDs that will be printed on the plot. If empty, IDs will be generated for each
+        plot. Default: [].
     location : str, optional
         Location for ID to be displayed on the plot. Default is "east".
     rotation: float or int, optional
diff --git a/tests/test_tagplot_image.py b/tests/test_tagplot_image.py
index 41fcc73..2a9c1f8 100644
--- a/tests/test_tagplot_image.py
+++ b/tests/test_tagplot_image.py
@@ -43,11 +43,12 @@ class TestTagplotImage(unittest.TestCase):
             IMGS_AS_LIST,
             ROTATION,
             POSITION,
+            figure_ids=["test123456", "654321tset"],
             prefix=PROJECT_ID,
             id_method=METHOD,
             qrcode=True,
             fontsize=10,
-            font="fonts/xolonium-fonts-4.1/ttf/Xolonium-Bold.ttf",
+            font="tests/fonts/xolonium-fonts-4.1/ttf/Xolonium-Bold.ttf",
             fontcolor=(0, 1, 0),
         )
         options.validate_input()
diff --git a/tests/test_tagplot_matplotlib.py b/tests/test_tagplot_matplotlib.py
index af3f74f..6ce909f 100644
--- a/tests/test_tagplot_matplotlib.py
+++ b/tests/test_tagplot_matplotlib.py
@@ -33,6 +33,7 @@ class TestTagplotMatplotlib(unittest.TestCase):
             FIGS_AS_LIST,
             ROTATION,
             POSITION,
+            figure_ids=["test123456", "654321tset"],
             prefix=PROJECT_ID,
             id_method=METHOD,
             qrcode=True,
-- 
GitLab