diff options
author | rsiddharth <s@ricketyspace.net> | 2016-11-13 00:47:39 +0000 |
---|---|---|
committer | rsiddharth <s@ricketyspace.net> | 2016-11-13 00:47:39 +0000 |
commit | b2b065cbb8aa2c48c1058ab22efeae3f5bfbe9b2 (patch) | |
tree | d2ceddd5c3d032b20d98f862233070bb0bfea39e /tests | |
parent | 859079274081b6160aa09a55fa6a67075ff62b37 (diff) |
Add `config_dir` function.
* gd_diff.py (config_dir): New function.
* tests/test_gd_diff.py (test_config_dir): Add test function for
`config_dir`.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/test_gd_diff.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/test_gd_diff.py b/tests/test_gd_diff.py index ff4cf7a..0120718 100644 --- a/tests/test_gd_diff.py +++ b/tests/test_gd_diff.py @@ -226,6 +226,16 @@ class TestGdDiff(object): 'Removed example with non-free files.') + def test_config_dir(self): + def env(e): + return self.test_home + + with mock.patch('os.getenv', new=env): + c_dir = config_dir() + assert_equal(c_dir, os.path.join(self.test_home, + '.config', 'gns-deb-diff')) + + def teardown(self): """Teardown method for this class.""" if(path.exists(self.gns_pkgs_dir)): |