Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(97)

Unified Diff: base/scoped_temp_dir_unittest.cc

Issue 6042009: Added WARN_UNUSED_RESULT to ScopedTempDir methods. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge with trunk Created 9 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/scoped_temp_dir.h ('k') | chrome/browser/extensions/convert_web_app_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/scoped_temp_dir_unittest.cc
diff --git a/base/scoped_temp_dir_unittest.cc b/base/scoped_temp_dir_unittest.cc
index 039a1edb39c6d8c0f72e9f2058126c3dd98f5a2c..135c2fd809870760f5ab2c61823ad6986bf00140 100644
--- a/base/scoped_temp_dir_unittest.cc
+++ b/base/scoped_temp_dir_unittest.cc
@@ -23,7 +23,7 @@ TEST(ScopedTempDir, FullPath) {
{
ScopedTempDir dir;
- dir.Set(test_path);
+ EXPECT_TRUE(dir.Set(test_path));
// Now the dir doesn't exist, so ensure that it gets created.
EXPECT_TRUE(file_util::DirectoryExists(test_path));
// When we call Release(), it shouldn't get destroyed when leaving scope.
@@ -36,7 +36,7 @@ TEST(ScopedTempDir, FullPath) {
// Clean up.
{
ScopedTempDir dir;
- dir.Set(test_path);
+ EXPECT_TRUE(dir.Set(test_path));
}
EXPECT_FALSE(file_util::DirectoryExists(test_path));
}
@@ -83,7 +83,7 @@ TEST(ScopedTempDir, MultipleInvocations) {
EXPECT_TRUE(dir.CreateUniqueTempDir());
EXPECT_FALSE(dir.CreateUniqueTempDir());
ScopedTempDir other_dir;
- other_dir.Set(dir.Take());
+ EXPECT_TRUE(other_dir.Set(dir.Take()));
EXPECT_TRUE(dir.CreateUniqueTempDir());
EXPECT_FALSE(dir.CreateUniqueTempDir());
EXPECT_FALSE(other_dir.CreateUniqueTempDir());
« no previous file with comments | « base/scoped_temp_dir.h ('k') | chrome/browser/extensions/convert_web_app_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698