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

Side by Side Diff: sandbox/win/src/sync_policy_test.cc

Issue 10689170: Move the Windows sandbox to sandbox/win (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase on top of tree (properly this time) Created 8 years, 5 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
« no previous file with comments | « sandbox/win/src/sync_policy.cc ('k') | sandbox/win/src/target_interceptions.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 (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #include "base/win/scoped_handle.h" 5 #include "base/win/scoped_handle.h"
6 #include "sandbox/src/sandbox.h" 6 #include "sandbox/win/src/sandbox.h"
7 #include "sandbox/src/sandbox_policy.h" 7 #include "sandbox/win/src/sandbox_policy.h"
8 #include "sandbox/src/sandbox_factory.h" 8 #include "sandbox/win/src/sandbox_factory.h"
9 #include "sandbox/src/nt_internals.h" 9 #include "sandbox/win/src/nt_internals.h"
10 #include "sandbox/tests/common/controller.h" 10 #include "sandbox/win/tests/common/controller.h"
11 #include "testing/gtest/include/gtest/gtest.h" 11 #include "testing/gtest/include/gtest/gtest.h"
12 12
13 namespace sandbox { 13 namespace sandbox {
14 14
15 SBOX_TESTS_COMMAND int Event_Open(int argc, wchar_t **argv) { 15 SBOX_TESTS_COMMAND int Event_Open(int argc, wchar_t **argv) {
16 if (argc != 2) 16 if (argc != 2)
17 return SBOX_TEST_FAILED_TO_EXECUTE_COMMAND; 17 return SBOX_TEST_FAILED_TO_EXECUTE_COMMAND;
18 18
19 DWORD desired_access = SYNCHRONIZE; 19 DWORD desired_access = SYNCHRONIZE;
20 if (L'f' == argv[0][0]) 20 if (L'f' == argv[0][0])
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 EXPECT_EQ(SBOX_TEST_SUCCEEDED, runner.RunTest(L"Event_Open s test2")); 136 EXPECT_EQ(SBOX_TEST_SUCCEEDED, runner.RunTest(L"Event_Open s test2"));
137 EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"Event_Open f test3")); 137 EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"Event_Open f test3"));
138 EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"Event_Open s test4")); 138 EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"Event_Open s test4"));
139 EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"Event_CreateOpen f f test5")); 139 EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"Event_CreateOpen f f test5"));
140 EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"Event_CreateOpen t f test6")); 140 EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"Event_CreateOpen t f test6"));
141 EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"Event_CreateOpen f t test5")); 141 EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"Event_CreateOpen f t test5"));
142 EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"Event_CreateOpen t t test6")); 142 EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"Event_CreateOpen t t test6"));
143 } 143 }
144 144
145 } // namespace sandbox 145 } // namespace sandbox
OLDNEW
« no previous file with comments | « sandbox/win/src/sync_policy.cc ('k') | sandbox/win/src/target_interceptions.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698