Commit dae63825 authored by WillBrennan's avatar WillBrennan

added outline of unit tests

parent eb7c58fe
...@@ -2,7 +2,9 @@ ...@@ -2,7 +2,9 @@
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
__author__ = 'willbrennan' __author__ = 'willbrennan'
from skin_detector import process from skin_detector import *
from scripts import display from scripts import display
__all__ = ["process", "display"] __all__ = [
\ No newline at end of file "process", "display", "get_hsv_mask", "get_rgb_mask", "get_ycrcb_mask", "grab_cut_mask", "grab_cut_mask", "closing"
]
import cv2 import cv2
import numpy import numpy
import skin_detector
def test_get_hsv_mask(): def test_get_hsv_mask():
img = cv2.imread("../test_image.png") img = cv2.imread("../test_image.png")
assert True mask = skin_detector.get_hsv_mask(img)
assert img.shape[:2] == mask.shape
def test_get_rgb_mask(): def test_get_rgb_mask():
img = cv2.imread("../test_image.png") img = cv2.imread("../test_image.png")
assert True mask = skin_detector.get_rgb_mask(img)
assert img.shape[:2] == mask.shape
def test_get_ycrcb_mask(): def test_get_ycrcb_mask():
img = cv2.imread("../test_image.png") img = cv2.imread("../test_image.png")
assert True mask = skin_detector.get_ycrcb_mask(img)
assert img.shape[:2] == mask.shape
def test_grab_cut_mask(): def test_grab_cut_mask():
img = cv2.imread("../test_image.png") img = cv2.imread("../test_image.png")
assert True assert True
def test_closing(): def test_closing():
img = cv2.imread("../test_image.png") img = cv2.imread("../test_image.png")
assert True assert True
def test_process(): def test_process():
img = cv2.imread("../test_image.png") img = cv2.imread("../test_image.png")
assert True assert True
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment