Skip to content
Snippets Groups Projects
Commit 21baea57 authored by André Anjos's avatar André Anjos :speech_balloon:
Browse files

Fix tests (closes #6)

parent ccd5a085
Branches
Tags
1 merge request!12Issue 6
......@@ -22,7 +22,10 @@ from bob.bio.vein.database import UtfvpBioDatabase
utfvp_directory = "[YOUR_UTFVP_DIRECTORY]"
"""Value of ``~/.bob_bio_databases.txt`` for this database"""
database = UtfvpBioDatabase(original_directory = utfvp_directory)
database = UtfvpBioDatabase(
original_directory = utfvp_directory,
original_extension = '.png',
)
"""The :py:class:`bob.bio.base.database.BioDatabase` derivative with UTFVP settings
.. warning::
......
......@@ -20,7 +20,10 @@ from bob.bio.vein.database import VerafingerBioDatabase
verafinger_directory = "[YOUR_VERAFINGER_DIRECTORY]"
"""Value of ``~/.bob_bio_databases.txt`` for this database"""
database = VerafingerBioDatabase(original_directory = verafinger_directory)
database = VerafingerBioDatabase(
original_directory = verafinger_directory,
original_extension = '.png',
)
"""The :py:class:`bob.bio.base.database.BioDatabase` derivative with Verafinger
database settings
......
......@@ -3,7 +3,7 @@
# Tue 27 Sep 2016 16:49:05 CEST
from .database import VeinBioFile
from bob.bio.base.database import BioDatabase, BioFile
from bob.bio.base.database import BioDatabase
class UtfvpBioDatabase(BioDatabase):
......
......@@ -4,7 +4,7 @@
from .database import VeinBioFile
from bob.bio.base.database import BioDatabase, BioFile
from bob.bio.base.database import BioDatabase
class VerafingerBioDatabase(BioDatabase):
......
......@@ -6,14 +6,16 @@ from nose.plugins.skip import SkipTest
import bob.bio.base
from bob.bio.base.test.utils import db_available
from bob.bio.base.test.test_database_implementations import check_database, check_database_zt
from bob.bio.base.test.test_database_implementations import check_database
@db_available('utfvp')
def test_utfvp():
database = bob.bio.base.load_resource('utfvp', 'database', preferred_package='bob.bio.vein')
module = bob.bio.base.load_resource('utfvp', 'config',
preferred_package='bob.bio.vein')
try:
check_database(database, protocol='nomLeftRing', groups=('dev', 'eval'))
check_database(module.database, protocol=module.protocol,
groups=('dev', 'eval'))
except IOError as e:
raise SkipTest(
"The database could not queried; probably the db.sql3 file is missing. Here is the error: '%s'" % e)
......@@ -21,9 +23,11 @@ def test_utfvp():
@db_available('verafinger')
def test_verafinger():
database = bob.bio.base.load_resource('verafinger', 'database', preferred_package='bob.bio.vein')
module = bob.bio.base.load_resource('verafinger', 'config',
preferred_package='bob.bio.vein')
try:
check_database(database, protocol='Fifty', groups=('dev', 'eval'))
check_database(module.database, protocol='Fifty', groups=('dev',
'eval'))
except IOError as e:
raise SkipTest(
"The database could not queried; probably the db.sql3 file is missing. Here is the error: '%s'" % e)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment