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

Side by Side Diff: native_client_sdk/src/libraries/c_salt/test/gtest_nacl_environment.h

Issue 10854137: [NaCl SDK] gtest_ppapi library. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: remove hacks Created 8 years, 4 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef C_SALT_TEST_GTEST_NACL_ENVIRONMENT_H_
6 #define C_SALT_TEST_GTEST_NACL_ENVIRONMENT_H_
7
8 #include <cassert>
9 #include "gtest/gtest.h"
10
11 namespace pp {
12 class Instance;
13 } // namespace pp
14
15 namespace c_salt {
16
17 // A custom environment for NaCl gtest.
18 class GTestNaclEnvironment : public ::testing::Environment {
19 public:
20 // Set the global NaCl instance that will be shared by all the tests.
21 static void set_global_instance(pp::Instance* instance) {
22 global_instance_ = instance;
23 }
24
25 // Get the global NaCl instance.
26 static pp::Instance* global_instance() { return global_instance_; }
27
28 // Environment overrides.
29 virtual void SetUp();
30 virtual void TearDown();
31
32 private:
33 static pp::Instance* global_instance_;
34 };
35
36 } // namespace c_salt
37
38 #endif // C_SALT_TEST_GTEST_NACL_ENVIRONMENT_H_
39
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698