@@ -0,0 +1,1328 @@
+import pytest%0Aimport numpy as np%0Afrom plantcv.plantcv.visualize import colorize_masks%0A%0A%0A@pytest.mark.parametrize('colors', %5B%5B'red', 'blue'%5D, %5B(0, 0, 255), (255, 0, 0)%5D%5D)%0Adef test_colorize_masks(colors):%0A    # Create test data%0A    mask1 = np.zeros((100, 100), dtype=np.uint8)%0A    mask2 = np.copy(mask1)%0A    mask1%5B0:50, 0:50%5D = 255%0A    mask2%5B50:100, 50:100%5D = 255%0A    colored_img = colorize_masks(masks=%5Bmask1, mask2%5D, colors=colors)%0A    # Assert that the output image has the dimensions of the input image%0A    assert not np.average(colored_img) == 0%0A%0A%0Adef test_colorize_masks_bad_input_empty():%0A    with pytest.raises(RuntimeError):%0A        _ = colorize_masks(masks=%5B%5D, colors=%5B%5D)%0A%0A%0Adef test_colorize_masks_bad_input_mismatch_number():%0A    # Create test data%0A    mask1 = np.zeros((100, 100), dtype=np.uint8)%0A    mask2 = np.copy(mask1)%0A    mask1%5B0:50, 0:50%5D = 255%0A    mask2%5B50:100, 50:100%5D = 255%0A    with pytest.raises(RuntimeError):%0A        _ = colorize_masks(masks=%5Bmask1, mask2%5D, colors=%5B'red', 'green', 'blue'%5D)%0A%0A%0Adef test_colorize_masks_bad_color_input():%0A    # Create test data%0A    mask1 = np.zeros((100, 100), dtype=np.uint8)%0A    mask2 = np.copy(mask1)%0A    mask1%5B0:50, 0:50%5D = 255%0A    mask2%5B50:100, 50:100%5D = 255%0A    with pytest.raises(RuntimeError):%0A        _ = colorize_masks(masks=%5Bmask1, mask2%5D, colors=%5B'red', 1.123%5D)%0A

Create colorize_masks tests module