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

Side by Side Diff: chrome/test/ui/npapi_test_helper.cc

Issue 3012021: CommandLine: add a CopySwitchesFrom() for copying from another CommandLine (Closed)
Patch Set: minor cleanups Created 10 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
« no previous file with comments | « chrome/test/plugin/plugin_test.cpp ('k') | chrome/test/ui/ppapi_uitest.cc » ('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 2008, Google Inc. 1 // Copyright 2008, Google Inc.
2 // All rights reserved. 2 // All rights reserved.
3 // 3 //
4 // Redistribution and use in source and binary forms, with or without 4 // Redistribution and use in source and binary forms, with or without
5 // modification, are permitted provided that the following conditions are 5 // modification, are permitted provided that the following conditions are
6 // met: 6 // met:
7 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 7 // Copyright (c) 2009 The Chromium Authors. All rights reserved.
8 // Use of this source code is governed by a BSD-style license that can be 8 // Use of this source code is governed by a BSD-style license that can be
9 // found in the LICENSE file. 9 // found in the LICENSE file.
10 10
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 ASSERT_TRUE(file_util::PathExists(plugin_src)); 42 ASSERT_TRUE(file_util::PathExists(plugin_src));
43 test_plugin_path_ = plugins_directory.AppendASCII(test_plugin_name_); 43 test_plugin_path_ = plugins_directory.AppendASCII(test_plugin_name_);
44 44
45 file_util::CreateDirectory(plugins_directory); 45 file_util::CreateDirectory(plugins_directory);
46 ASSERT_TRUE(file_util::CopyDirectory(plugin_src, test_plugin_path_, true)) 46 ASSERT_TRUE(file_util::CopyDirectory(plugin_src, test_plugin_path_, true))
47 << "Copy failed from " << plugin_src.value() 47 << "Copy failed from " << plugin_src.value()
48 << " to " << test_plugin_path_.value(); 48 << " to " << test_plugin_path_.value();
49 #if defined(OS_MACOSX) 49 #if defined(OS_MACOSX)
50 // The plugins directory isn't read by default on the Mac, so it needs to be 50 // The plugins directory isn't read by default on the Mac, so it needs to be
51 // explicitly registered. 51 // explicitly registered.
52 launch_arguments_.AppendSwitchWithValue(switches::kExtraPluginDir, 52 launch_arguments_.AppendSwitchPath(switches::kExtraPluginDir,
53 plugins_directory.value()); 53 plugins_directory);
54 #endif 54 #endif
55 55
56 UITest::SetUp(); 56 UITest::SetUp();
57 } 57 }
58 58
59 void NPAPITesterBase::TearDown() { 59 void NPAPITesterBase::TearDown() {
60 // Tear down the UI test first so that the browser stops using the plugin 60 // Tear down the UI test first so that the browser stops using the plugin
61 // files. 61 // files.
62 UITest::TearDown(); 62 UITest::TearDown();
63 EXPECT_TRUE(file_util::DieFileDie(test_plugin_path_, true)); 63 EXPECT_TRUE(file_util::DieFileDie(test_plugin_path_, true));
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 void NPAPIVisiblePluginTester::SetUp() { 100 void NPAPIVisiblePluginTester::SetUp() {
101 show_window_ = true; 101 show_window_ = true;
102 NPAPITester::SetUp(); 102 NPAPITester::SetUp();
103 } 103 }
104 104
105 // NPAPIIncognitoTester members. 105 // NPAPIIncognitoTester members.
106 void NPAPIIncognitoTester::SetUp() { 106 void NPAPIIncognitoTester::SetUp() {
107 launch_arguments_.AppendSwitch(switches::kIncognito); 107 launch_arguments_.AppendSwitch(switches::kIncognito);
108 NPAPITester::SetUp(); 108 NPAPITester::SetUp();
109 } 109 }
OLDNEW
« no previous file with comments | « chrome/test/plugin/plugin_test.cpp ('k') | chrome/test/ui/ppapi_uitest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698