summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorDavid Kalnischkies <kalnischkies@gmail.com>2012-04-23 19:33:32 +0200
committerDavid Kalnischkies <kalnischkies@gmail.com>2012-04-23 19:33:32 +0200
commitaf13d1437cbcb383de89f126b316c02587e4b691 (patch)
treeef59465fbafa3dab7aa81070b2411f885695762f /test
parentec76891fa17c77f8fd28b9b6e11ef2d7547afe7e (diff)
downloadapt-af13d1437cbcb383de89f126b316c02587e4b691.tar.gz
/dev/null is a special absolute path as it has no subdirectories
Diffstat (limited to 'test')
-rw-r--r--test/libapt/configuration_test.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/test/libapt/configuration_test.cc b/test/libapt/configuration_test.cc
index 6b657a70c..87d5699ef 100644
--- a/test/libapt/configuration_test.cc
+++ b/test/libapt/configuration_test.cc
@@ -93,6 +93,11 @@ int main(int argc,const char *argv[]) {
equals(Cnf.FindFile("Dir::State"), "/rootdir/srv/sid/var/lib/apt");
equals(Cnf.FindFile("Dir::Aptitude::State"), "/rootdir/srv/sid/var/lib/aptitude");
+ Cnf.Set("Dir::State", "/dev/null");
+ Cnf.Set("Dir::State::lists", "lists/");
+ equals(Cnf.FindDir("Dir::State"), "/rootdir/dev/null");
+ equals(Cnf.FindDir("Dir::State::lists"), "/rootdir/dev/null");
+
//FIXME: Test for configuration file parsing;
// currently only integration/ tests test them implicitly