summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMichael Vogt <mvo@ubuntu.com>2014-04-28 17:44:34 +0200
committerMichael Vogt <mvo@ubuntu.com>2014-04-28 17:44:34 +0200
commita111a024a30b805fc3f2b8a5b4db8d0c26c10fb8 (patch)
treed4d28cd0fe5074e164cef440760f33361d90d262 /test
parent53ac87ac9c27af39df062516aab5dce880af107a (diff)
fix tests
Diffstat (limited to 'test')
-rw-r--r--test/libapt/fileutl_test.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/libapt/fileutl_test.cc b/test/libapt/fileutl_test.cc
index 9c7e1630a..15b57983b 100644
--- a/test/libapt/fileutl_test.cc
+++ b/test/libapt/fileutl_test.cc
@@ -226,8 +226,12 @@ TEST(FileUtlTest, GetTempDir)
}
TEST(FileUtlTest, flAbsPath)
{
+ std::string cwd = SafeGetCWD();
int res = chdir("/bin/");
EXPECT_EQ(res, 0);
std::string p = flAbsPath("ls");
EXPECT_EQ(p, "/bin/ls");
+
+ res = chdir(cwd.c_str());
+ EXPECT_EQ(res, 0);
}