summaryrefslogtreecommitdiffstats
path: root/sandbox/win
diff options
context:
space:
mode:
authorthakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-07-07 03:23:18 +0000
committerthakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-07-07 03:23:18 +0000
commitf22ba68e10f9a5d779853ff8067c10e98eb793c3 (patch)
treee9d9ce81dd7db2ac5d68d3e7f9cf7072c8aebbf5 /sandbox/win
parent50afe47d1a6cff2fba76db9badede7364b9a6264 (diff)
downloadchromium_src-f22ba68e10f9a5d779853ff8067c10e98eb793c3.zip
chromium_src-f22ba68e10f9a5d779853ff8067c10e98eb793c3.tar.gz
chromium_src-f22ba68e10f9a5d779853ff8067c10e98eb793c3.tar.bz2
win sandbox tests: Rename OpenFile to OpenFileCmd.
Fixes: ..\..\sandbox\win\tests\validation_tests\commands.cc(142,24) : error(clang): conflicting types for 'OpenFile' SBOX_TESTS_COMMAND int OpenFile(int argc, wchar_t **argv) { ^ E:\b\depot_tools\win_toolchain\vs2013_files\win8sdk\Include\um\winbase.h(4121,1) : note(clang): previous declaration is here OpenFile( ^ 1 error generated. BUG=391347 TBR=jschuh@chromium.org NOTRY=true Review URL: https://codereview.chromium.org/373723002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@281491 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'sandbox/win')
-rw-r--r--sandbox/win/tests/validation_tests/commands.cc4
-rw-r--r--sandbox/win/tests/validation_tests/suite.cc18
2 files changed, 11 insertions, 11 deletions
diff --git a/sandbox/win/tests/validation_tests/commands.cc b/sandbox/win/tests/validation_tests/commands.cc
index 4b12094..2613347 100644
--- a/sandbox/win/tests/validation_tests/commands.cc
+++ b/sandbox/win/tests/validation_tests/commands.cc
@@ -139,7 +139,7 @@ int TestOpenThread(DWORD thread_id) {
}
}
-SBOX_TESTS_COMMAND int OpenFile(int argc, wchar_t **argv) {
+SBOX_TESTS_COMMAND int OpenFileCmd(int argc, wchar_t **argv) {
if (1 != argc)
return SBOX_TEST_FAILED_TO_EXECUTE_COMMAND;
@@ -161,7 +161,7 @@ int TestOpenWriteFile(int argc, wchar_t **argv) {
trim_quote(&path);
return TestOpenWriteFile(path);
- }
+}
int TestOpenWriteFile(const base::string16& path) {
return TestOpenFile(path, true);
diff --git a/sandbox/win/tests/validation_tests/suite.cc b/sandbox/win/tests/validation_tests/suite.cc
index df50c56..afb00b5 100644
--- a/sandbox/win/tests/validation_tests/suite.cc
+++ b/sandbox/win/tests/validation_tests/suite.cc
@@ -80,19 +80,19 @@ TEST(ValidationSuite, TestFileSystem) {
ASSERT_TRUE(VolumeSupportsACLs(L"%AppData%\\"));
TestRunner runner;
- EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"OpenFile %SystemDrive%"));
- EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"OpenFile %SystemRoot%"));
- EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"OpenFile %ProgramFiles%"));
+ EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"OpenFileCmd %SystemDrive%"));
+ EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"OpenFileCmd %SystemRoot%"));
+ EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"OpenFileCmd %ProgramFiles%"));
EXPECT_EQ(SBOX_TEST_DENIED,
- runner.RunTest(L"OpenFile %SystemRoot%\\System32"));
+ runner.RunTest(L"OpenFileCmd %SystemRoot%\\System32"));
EXPECT_EQ(SBOX_TEST_DENIED,
- runner.RunTest(L"OpenFile %SystemRoot%\\explorer.exe"));
+ runner.RunTest(L"OpenFileCmd %SystemRoot%\\explorer.exe"));
EXPECT_EQ(SBOX_TEST_DENIED,
- runner.RunTest(L"OpenFile %SystemRoot%\\Cursors\\arrow_i.cur"));
+ runner.RunTest(L"OpenFileCmd %SystemRoot%\\Cursors\\arrow_i.cur"));
EXPECT_EQ(SBOX_TEST_DENIED,
- runner.RunTest(L"OpenFile %AllUsersProfile%"));
- EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"OpenFile %Temp%"));
- EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"OpenFile %AppData%"));
+ runner.RunTest(L"OpenFileCmd %AllUsersProfile%"));
+ EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"OpenFileCmd %Temp%"));
+ EXPECT_EQ(SBOX_TEST_DENIED, runner.RunTest(L"OpenFileCmd %AppData%"));
}
// Tests if the registry is correctly protected by the sandbox.