separated opencv 1.x and opencv 2.x wrappers. moved tests/python/* to modules/python/test

This commit is contained in:
Vadim Pisarevsky
2011-05-03 16:00:31 +00:00
parent 0c9e5f6c9c
commit 7f7965bc93
19 changed files with 4614 additions and 6993 deletions

View File

@@ -0,0 +1,16 @@
import urllib
import cv
import Image
import unittest
class TestLoadImage(unittest.TestCase):
def setUp(self):
open("large.jpg", "w").write(urllib.urlopen("http://www.cs.ubc.ca/labs/lci/curious_george/img/ROS_bug_imgs/IMG_3560.jpg").read())
def test_load(self):
pilim = Image.open("large.jpg")
cvim = cv.LoadImage("large.jpg")
self.assert_(len(pilim.tostring()) == len(cvim.tostring()))
if __name__ == '__main__':
unittest.main()