Test reading config from disk again
This commit is contained in:
parent
709c573b65
commit
962fd486af
|
@ -18,3 +18,12 @@ def test_config(config):
|
||||||
assert config.get('General', 'log') == 'tsstats/tests/res/test.log'
|
assert config.get('General', 'log') == 'tsstats/tests/res/test.log'
|
||||||
config.set('General', 'output', 'output.html')
|
config.set('General', 'output', 'output.html')
|
||||||
assert config.get('General', 'output') == 'output.html'
|
assert config.get('General', 'output') == 'output.html'
|
||||||
|
|
||||||
|
|
||||||
|
def test_read():
|
||||||
|
config = load(path='tsstats/tests/res/config.ini')
|
||||||
|
# test defaults
|
||||||
|
assert not config.getboolean('General', 'debug')
|
||||||
|
# test written values
|
||||||
|
assert config.get('General', 'log') == 'tsstats/tests/res/test.log'
|
||||||
|
assert config.get('General', 'output') == 'tsstats/tests/res/output.html'
|
||||||
|
|
Loading…
Reference in New Issue