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

Side by Side Diff: chrome/test/ppapi/ppapi_test.cc

Issue 23326003: Enable PNaCl by default (revert disabling CL) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 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 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 "chrome/test/ppapi/ppapi_test.h" 5 #include "chrome/test/ppapi/ppapi_test.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/file_util.h" 8 #include "base/file_util.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/path_service.h" 10 #include "base/path_service.h"
(...skipping 310 matching lines...) Expand 10 before | Expand all | Expand 10 after
321 command_line->AppendSwitch(switches::kUseFakeUIForMediaStream); 321 command_line->AppendSwitch(switches::kUseFakeUIForMediaStream);
322 } 322 }
323 323
324 void PPAPINaClTest::SetUpCommandLine(CommandLine* command_line) { 324 void PPAPINaClTest::SetUpCommandLine(CommandLine* command_line) {
325 PPAPITestBase::SetUpCommandLine(command_line); 325 PPAPITestBase::SetUpCommandLine(command_line);
326 326
327 base::FilePath plugin_lib; 327 base::FilePath plugin_lib;
328 EXPECT_TRUE(PathService::Get(chrome::FILE_NACL_PLUGIN, &plugin_lib)); 328 EXPECT_TRUE(PathService::Get(chrome::FILE_NACL_PLUGIN, &plugin_lib));
329 EXPECT_TRUE(base::PathExists(plugin_lib)); 329 EXPECT_TRUE(base::PathExists(plugin_lib));
330 330
331 // Enable running NaCl outside of the store. 331 // Enable running (non-portable) NaCl outside of the Chrome web store.
332 command_line->AppendSwitch(switches::kEnableNaCl); 332 command_line->AppendSwitch(switches::kEnableNaCl);
333 command_line->AppendSwitch(switches::kEnablePnacl);
334 command_line->AppendSwitchASCII(switches::kAllowNaClSocketAPI, "127.0.0.1"); 333 command_line->AppendSwitchASCII(switches::kAllowNaClSocketAPI, "127.0.0.1");
335 command_line->AppendSwitch(switches::kUseFakeDeviceForMediaStream); 334 command_line->AppendSwitch(switches::kUseFakeDeviceForMediaStream);
336 command_line->AppendSwitch(switches::kUseFakeUIForMediaStream); 335 command_line->AppendSwitch(switches::kUseFakeUIForMediaStream);
337 } 336 }
338 337
339 // Append the correct mode and testcase string 338 // Append the correct mode and testcase string
340 std::string PPAPINaClNewlibTest::BuildQuery(const std::string& base, 339 std::string PPAPINaClNewlibTest::BuildQuery(const std::string& base,
341 const std::string& test_case) { 340 const std::string& test_case) {
342 return base::StringPrintf("%smode=nacl_newlib&testcase=%s", base.c_str(), 341 return base::StringPrintf("%smode=nacl_newlib&testcase=%s", base.c_str(),
343 test_case.c_str()); 342 test_case.c_str());
(...skipping 14 matching lines...) Expand all
358 } 357 }
359 358
360 void PPAPINaClTestDisallowedSockets::SetUpCommandLine( 359 void PPAPINaClTestDisallowedSockets::SetUpCommandLine(
361 CommandLine* command_line) { 360 CommandLine* command_line) {
362 PPAPITestBase::SetUpCommandLine(command_line); 361 PPAPITestBase::SetUpCommandLine(command_line);
363 362
364 base::FilePath plugin_lib; 363 base::FilePath plugin_lib;
365 EXPECT_TRUE(PathService::Get(chrome::FILE_NACL_PLUGIN, &plugin_lib)); 364 EXPECT_TRUE(PathService::Get(chrome::FILE_NACL_PLUGIN, &plugin_lib));
366 EXPECT_TRUE(base::PathExists(plugin_lib)); 365 EXPECT_TRUE(base::PathExists(plugin_lib));
367 366
368 // Enable running NaCl outside of the store. 367 // Enable running (non-portable) NaCl outside of the Chrome web store.
369 command_line->AppendSwitch(switches::kEnableNaCl); 368 command_line->AppendSwitch(switches::kEnableNaCl);
370 command_line->AppendSwitch(switches::kEnablePnacl);
371 } 369 }
372 370
373 // Append the correct mode and testcase string 371 // Append the correct mode and testcase string
374 std::string PPAPINaClTestDisallowedSockets::BuildQuery( 372 std::string PPAPINaClTestDisallowedSockets::BuildQuery(
375 const std::string& base, 373 const std::string& base,
376 const std::string& test_case) { 374 const std::string& test_case) {
377 return base::StringPrintf("%smode=nacl_newlib&testcase=%s", base.c_str(), 375 return base::StringPrintf("%smode=nacl_newlib&testcase=%s", base.c_str(),
378 test_case.c_str()); 376 test_case.c_str());
379 } 377 }
380 378
381 void PPAPIBrokerInfoBarTest::SetUpOnMainThread() { 379 void PPAPIBrokerInfoBarTest::SetUpOnMainThread() {
382 // The default content setting for the PPAPI broker is ASK. We purposefully 380 // The default content setting for the PPAPI broker is ASK. We purposefully
383 // don't call PPAPITestBase::SetUpOnMainThread() to keep it that way. 381 // don't call PPAPITestBase::SetUpOnMainThread() to keep it that way.
384 } 382 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698