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

Unified Diff: base/test/scoped_path_override.cc

Issue 761903003: Update from https://crrev.com/306655 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years 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/test/scoped_path_override.h ('k') | base/test/test_suite.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/test/scoped_path_override.cc
diff --git a/base/test/scoped_path_override.cc b/base/test/scoped_path_override.cc
index 495ba2fbaf788518fb05aad7454eb6e20947938b..9a776118d20e699ce8d4ef1cb345867d6ae18014 100644
--- a/base/test/scoped_path_override.cc
+++ b/base/test/scoped_path_override.cc
@@ -22,6 +22,16 @@ ScopedPathOverride::ScopedPathOverride(int key, const base::FilePath& dir)
CHECK(result);
}
+ScopedPathOverride::ScopedPathOverride(int key,
+ const FilePath& path,
+ bool is_absolute,
+ bool create)
+ : key_(key) {
+ bool result =
+ PathService::OverrideAndCreateIfNeeded(key, path, is_absolute, create);
+ CHECK(result);
+}
+
ScopedPathOverride::~ScopedPathOverride() {
bool result = PathService::RemoveOverride(key_);
CHECK(result) << "The override seems to have been removed already!";
« no previous file with comments | « base/test/scoped_path_override.h ('k') | base/test/test_suite.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698