Skip to content

Commit

Permalink
Adapted new frgc database test to new bob.db.frgc interface
Browse files Browse the repository at this point in the history
  • Loading branch information
Manuel Guenther committed Jun 29, 2015
1 parent c00b766 commit 441560f
Showing 1 changed file with 16 additions and 13 deletions.
29 changes: 16 additions & 13 deletions facereclib/tests/test_databases.py
Expand Up @@ -74,7 +74,7 @@ def test02_banca(self):
self.check_database_zt(self.config('banca_twothirds'))
self.check_annotations(self.config('banca'))
except IOError as e:
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the import error: '%s'" % e)
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the error: '%s'" % e)


def test03_xm2vts(self):
Expand All @@ -83,15 +83,15 @@ def test03_xm2vts(self):
self.check_database(self.config('xm2vts'), groups=('dev', 'eval'), protocol = 'darkened-lp1')
self.check_annotations(self.config('xm2vts'))
except IOError as e:
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the import error: '%s'" % e)
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the error: '%s'" % e)


def test04_scface(self):
try:
self.check_database_zt(self.config('scface'))
self.check_annotations(self.config('scface'))
except IOError as e:
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the import error: '%s'" % e)
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the error: '%s'" % e)


def test05_mobio(self):
Expand All @@ -102,7 +102,7 @@ def test05_mobio(self):
self.check_database_zt(self.config('mobio_female'))
self.check_annotations(self.config('mobio'))
except IOError as e:
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the import error: '%s'" % e)
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the error: '%s'" % e)


def test06_multipie(self):
Expand All @@ -113,7 +113,7 @@ def test06_multipie(self):
self.check_database_zt(self.config('multipie_P110'))
self.check_annotations(self.config('multipie'))
except IOError as e:
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the import error: '%s'" % e)
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the error: '%s'" % e)


def test07_lfw(self):
Expand All @@ -122,29 +122,33 @@ def test07_lfw(self):
self.check_database(self.config('lfw'), protocol = 'fold1')
self.check_database(self.config('lfw_unrestricted'))
except IOError as e:
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the import error: '%s'" % e)
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the error: '%s'" % e)


def test08_arface(self):
try:
self.check_database(self.config('arface'), groups=('dev', 'eval'))
self.check_annotations(self.config('arface'))
except IOError as e:
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the import error: '%s'" % e)
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the error: '%s'" % e)


def test09_gbu(self):
try:
self.check_database(self.config('gbu'))
self.check_annotations(self.config('gbu'))
except IOError as e:
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the import error: '%s'" % e)
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the error: '%s'" % e)


def test10_frgc(self):
self.check_database(self.config('frgc'))
self.check_database(self.config('frgc'), protocol = '2.0.2')
self.check_annotations(self.config('frgc'))
from xml.sax import SAXException
try:
self.check_database(self.config('frgc'))
self.check_database(self.config('frgc'), protocol = '2.0.2')
self.check_annotations(self.config('frgc'))
except SAXException as e:
raise SkipTest("The database could not queried; probably original protocol files of the database are not available. Here is the error: '%s'" % e)


def test11_caspeal(self):
Expand All @@ -153,7 +157,7 @@ def test11_caspeal(self):
self.check_database(self.config('caspeal'), protocol = 'aging')
self.check_annotations(self.config('caspeal'))
except IOError as e:
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the import error: '%s'" % e)
raise SkipTest("The database could not queried; probably the db.sql3 file is missing. Here is the error: '%s'" % e)


def test20_verification_filelist(self):
Expand Down Expand Up @@ -192,4 +196,3 @@ def check_files(f1, f2):
m1 = sorted([str(id) for id in db1.model_ids()])[0]
m2 = sorted([str(id) for id in db2.model_ids()])[0]
self.assertEqual(str(db1.client_id_from_model_id(m1)), db2.client_id_from_model_id(m2))

0 comments on commit 441560f

Please sign in to comment.