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

Side by Side Diff: mojo/edk/system/test/scoped_test_dir.h

Issue 1435043002: EDK: Sprinkle some more |final| secret sauce. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 1 month 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 unified diff | Download patch
« no previous file with comments | « no previous file | mojo/edk/system/test/stopwatch.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef MOJO_EDK_SYSTEM_TEST_SCOPED_TEST_DIR_H_ 5 #ifndef MOJO_EDK_SYSTEM_TEST_SCOPED_TEST_DIR_H_
6 #define MOJO_EDK_SYSTEM_TEST_SCOPED_TEST_DIR_H_ 6 #define MOJO_EDK_SYSTEM_TEST_SCOPED_TEST_DIR_H_
7 7
8 #include "base/files/scoped_temp_dir.h" 8 #include "base/files/scoped_temp_dir.h"
9 #include "mojo/edk/util/scoped_file.h" 9 #include "mojo/edk/util/scoped_file.h"
10 #include "mojo/public/cpp/system/macros.h" 10 #include "mojo/public/cpp/system/macros.h"
11 11
12 namespace mojo { 12 namespace mojo {
13 namespace system { 13 namespace system {
14 namespace test { 14 namespace test {
15 15
16 // Creates/destroyes a temporary directory for test purposes. (Unlike 16 // Creates/destroyes a temporary directory for test purposes. (Unlike
17 // |base::ScopedTempDir|, this automatically creates the temporary directory.) 17 // |base::ScopedTempDir|, this automatically creates the temporary directory.)
18 class ScopedTestDir { 18 class ScopedTestDir final {
19 public: 19 public:
20 ScopedTestDir(); 20 ScopedTestDir();
21 ~ScopedTestDir(); 21 ~ScopedTestDir();
22 22
23 util::ScopedFILE CreateFile(); 23 util::ScopedFILE CreateFile();
24 24
25 private: 25 private:
26 base::ScopedTempDir temp_dir_; 26 base::ScopedTempDir temp_dir_;
27 27
28 MOJO_DISALLOW_COPY_AND_ASSIGN(ScopedTestDir); 28 MOJO_DISALLOW_COPY_AND_ASSIGN(ScopedTestDir);
29 }; 29 };
30 30
31 } // namespace test 31 } // namespace test
32 } // namespace system 32 } // namespace system
33 } // namespace mojo 33 } // namespace mojo
34 34
35 #endif // MOJO_EDK_SYSTEM_TEST_SCOPED_TEST_DIR_H_ 35 #endif // MOJO_EDK_SYSTEM_TEST_SCOPED_TEST_DIR_H_
OLDNEW
« no previous file with comments | « no previous file | mojo/edk/system/test/stopwatch.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698