X-Git-Url: https://git.saurik.com/apt.git/blobdiff_plain/ec76891fa17c77f8fd28b9b6e11ef2d7547afe7e..2a49601f69e08f06fb2727d869d420daacdd09d5:/test/libapt/configuration_test.cc?ds=sidebyside diff --git a/test/libapt/configuration_test.cc b/test/libapt/configuration_test.cc index 6b657a70c..2c974ee0a 100644 --- a/test/libapt/configuration_test.cc +++ b/test/libapt/configuration_test.cc @@ -93,6 +93,15 @@ 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"); + + Cnf.Set("Moo::Bar", "1"); + Cnf.Clear(); + equals(Cnf.Find("Moo::Bar"), ""); + //FIXME: Test for configuration file parsing; // currently only integration/ tests test them implicitly