summaryrefslogtreecommitdiff
path: root/test/libapt/configuration_test.cc
diff options
context:
space:
mode:
Diffstat (limited to 'test/libapt/configuration_test.cc')
-rw-r--r--test/libapt/configuration_test.cc9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/libapt/configuration_test.cc b/test/libapt/configuration_test.cc
index 5b23d17fb..9a3e2c118 100644
--- a/test/libapt/configuration_test.cc
+++ b/test/libapt/configuration_test.cc
@@ -71,6 +71,15 @@ int main(int argc,const char *argv[]) {
equals(Cnf.Find("APT2::Version", "33"), "33");
equals(Cnf.FindI("APT2::Version", 33), 33);
+ equals(Cnf.FindFile("Dir::State"), "");
+ equals(Cnf.FindFile("Dir::Aptitude::State"), "");
+ Cnf.Set("Dir", "/srv/sid");
+ equals(Cnf.FindFile("Dir::State"), "");
+ Cnf.Set("Dir::State", "var/lib/apt");
+ Cnf.Set("Dir::Aptitude::State", "var/lib/aptitude");
+ equals(Cnf.FindFile("Dir::State"), "/srv/sid/var/lib/apt");
+ equals(Cnf.FindFile("Dir::Aptitude::State"), "/srv/sid/var/lib/aptitude");
+
//FIXME: Test for configuration file parsing;
// currently only integration/ tests test them implicitly