forked from openlp/openlp
Stubbed out a new test.
This commit is contained in:
parent
93fd476383
commit
e5b8a1b1ad
@ -127,7 +127,7 @@ class TestLibModule(TestCase):
|
||||
# GIVEN: A directory to check and a mocked out os.makedirs and os.path.exists
|
||||
directory_to_check = u'existing/directory'
|
||||
|
||||
# WHEN: os.path.exists returns Truew and we check to see if the directory exists
|
||||
# WHEN: os.path.exists returns True and we check to see if the directory exists
|
||||
mocked_exists.return_value = True
|
||||
check_directory_exists(directory_to_check)
|
||||
|
||||
@ -154,4 +154,5 @@ class TestLibModule(TestCase):
|
||||
mocked_exists.side_effect = ValueError()
|
||||
|
||||
# THEN: check_directory_exists raises an exception
|
||||
mocked_exists.assert_called_with(directory_to_check)
|
||||
self.assertRaises(ValueError, check_directory_exists, directory_to_check)
|
||||
|
19
tests/functional/openlp_core_utils/test_utils.py
Normal file
19
tests/functional/openlp_core_utils/test_utils.py
Normal file
@ -0,0 +1,19 @@
|
||||
"""
|
||||
Functional tests to test the AppLocation class and related methods.
|
||||
"""
|
||||
from unittest import TestCase
|
||||
|
||||
from mock import patch
|
||||
|
||||
from openlp.core.utils import get_filesystem_encoding
|
||||
|
||||
class TestUtils(TestCase):
|
||||
"""
|
||||
A test suite to test out various methods around the AppLocation class.
|
||||
"""
|
||||
def get_filesystem_encoding_test(self):
|
||||
"""
|
||||
Test the get_filesystem_encoding() function
|
||||
"""
|
||||
assert False, u'This test needs to be written'
|
||||
|
Loading…
Reference in New Issue
Block a user