diff options
author | ccameron@chromium.org <ccameron@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-12-10 13:57:32 +0000 |
---|---|---|
committer | ccameron@chromium.org <ccameron@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-12-10 13:57:32 +0000 |
commit | f5b7f6eaf180ec9b0b8a8536a9bcd731ca1031b1 (patch) | |
tree | 93a05fe890000b91f53a624ea50dc827f796959b /chrome | |
parent | 99c35445cc8a9ee68d2a9c1bc084d222ca2aa29c (diff) | |
download | chromium_src-f5b7f6eaf180ec9b0b8a8536a9bcd731ca1031b1.zip chromium_src-f5b7f6eaf180ec9b0b8a8536a9bcd731ca1031b1.tar.gz chromium_src-f5b7f6eaf180ec9b0b8a8536a9bcd731ca1031b1.tar.bz2 |
Tighten the blacklist on VMWare on OS X
There will no such thing as blacklisting just FCM in the future, so
first we will change these configurations to disable everything (so
they'll be like WinXP should be).
Fix up a number of tests that don't work when there is no GPU
process. It's not clear how these tests work on WinXP, so add a
temporary log statement in one of these tests so we can figure
out why they are passing on WinXP (they do not pass locally when
the GPU is blacklisted).
BUG=286038
Review URL: https://codereview.chromium.org/107093006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@239777 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
6 files changed, 50 insertions, 4 deletions
diff --git a/chrome/browser/autofill/risk/fingerprint_browsertest.cc b/chrome/browser/autofill/risk/fingerprint_browsertest.cc index 42b5ccb..1149f2d 100644 --- a/chrome/browser/autofill/risk/fingerprint_browsertest.cc +++ b/chrome/browser/autofill/risk/fingerprint_browsertest.cc @@ -11,6 +11,7 @@ #include "chrome/test/base/in_process_browser_test.h" #include "components/autofill/content/browser/risk/proto/fingerprint.pb.h" #include "content/public/browser/geolocation_provider.h" +#include "content/public/browser/gpu_data_manager.h" #include "content/public/common/geoposition.h" #include "content/public/test/test_utils.h" #include "testing/gmock/include/gmock/gmock.h" @@ -171,6 +172,11 @@ class AutofillRiskFingerprintTest : public InProcessBrowserTest { // Test that getting a fingerprint works on some basic level. IN_PROC_BROWSER_TEST_F(AutofillRiskFingerprintTest, GetFingerprint) { + // This test hangs when there is no GPU process. + // http://crbug.com/327272 + if (!content::GpuDataManager::GetInstance()->GpuAccessAllowed(NULL)) + return; + content::Geoposition position; position.latitude = kLatitude; position.longitude = kLongitude; diff --git a/chrome/browser/extensions/api/webstore_private/webstore_private_apitest.cc b/chrome/browser/extensions/api/webstore_private/webstore_private_apitest.cc index 4110415..925d235 100644 --- a/chrome/browser/extensions/api/webstore_private/webstore_private_apitest.cc +++ b/chrome/browser/extensions/api/webstore_private/webstore_private_apitest.cc @@ -313,6 +313,10 @@ IN_PROC_BROWSER_TEST_F(ExtensionWebstorePrivateApiTest, EmptyCrx) { class ExtensionWebstoreGetWebGLStatusTest : public InProcessBrowserTest { protected: void RunTest(bool webgl_allowed) { + // If Gpu access is disallowed then WebGL will not be available. + if (!content::GpuDataManager::GetInstance()->GpuAccessAllowed(NULL)) + webgl_allowed = false; + static const char kEmptyArgs[] = "[]"; static const char kWebGLStatusAllowed[] = "webgl_allowed"; static const char kWebGLStatusBlocked[] = "webgl_blocked"; diff --git a/chrome/browser/extensions/requirements_checker_browsertest.cc b/chrome/browser/extensions/requirements_checker_browsertest.cc index 6378424..300f530 100644 --- a/chrome/browser/extensions/requirements_checker_browsertest.cc +++ b/chrome/browser/extensions/requirements_checker_browsertest.cc @@ -173,9 +173,18 @@ IN_PROC_BROWSER_TEST_F(RequirementsCheckerBrowserTest, Check3DExtension) { LoadExtensionFromDirName("require_3d")); ASSERT_TRUE(extension.get()); + std::vector<std::string> expected_errors; + + if (!content::GpuDataManager::GetInstance()->GpuAccessAllowed(NULL)) { + expected_errors.push_back(l10n_util::GetStringUTF8( + IDS_EXTENSION_WEBGL_NOT_SUPPORTED)); + expected_errors.push_back(l10n_util::GetStringUTF8( + IDS_EXTENSION_CSS3D_NOT_SUPPORTED)); + } + checker_.Check(extension, base::Bind( &RequirementsCheckerBrowserTest::ValidateRequirementErrors, - base::Unretained(this), std::vector<std::string>())); + base::Unretained(this), expected_errors)); content::BrowserThread::GetBlockingPool()->FlushForTesting(); } diff --git a/chrome/browser/policy/policy_browsertest.cc b/chrome/browser/policy/policy_browsertest.cc index 2d8c175..ed05d3c 100644 --- a/chrome/browser/policy/policy_browsertest.cc +++ b/chrome/browser/policy/policy_browsertest.cc @@ -93,6 +93,7 @@ #include "content/public/browser/child_process_data.h" #include "content/public/browser/download_item.h" #include "content/public/browser/download_manager.h" +#include "content/public/browser/gpu_data_manager.h" #include "content/public/browser/notification_details.h" #include "content/public/browser/notification_observer.h" #include "content/public/browser/notification_registrar.h" @@ -1138,6 +1139,10 @@ IN_PROC_BROWSER_TEST_F(PolicyTest, ReplaceSearchTerms) { } IN_PROC_BROWSER_TEST_F(PolicyTest, Disable3DAPIs) { + // This test assumes Gpu access. + if (!content::GpuDataManager::GetInstance()->GpuAccessAllowed(NULL)) + return; + ui_test_utils::NavigateToURL(browser(), GURL(content::kAboutBlankURL)); // WebGL is enabled by default. content::WebContents* contents = diff --git a/chrome/test/gpu/gpu_feature_browsertest.cc b/chrome/test/gpu/gpu_feature_browsertest.cc index ac0b590..d20357e 100644 --- a/chrome/test/gpu/gpu_feature_browsertest.cc +++ b/chrome/test/gpu/gpu_feature_browsertest.cc @@ -169,11 +169,13 @@ class GpuFeatureTest : public InProcessBrowserTest { std::string trace_events_json_; }; -#if defined(OS_WIN) || defined(ADDRESS_SANITIZER) || defined(USE_AURA) +#if defined(OS_WIN) || defined(ADDRESS_SANITIZER) || defined(USE_AURA) || \ + defined(OS_MACOSX) // This test is flaky on Windows. http://crbug.com/177113 // Also fails under AddressSanitizer. http://crbug.com/185178 // It fundamentally doesn't test the right thing on Aura. // http://crbug.com/280675 +// This does not work with software compositing on Mac. http://crbug.com/286038 #define MAYBE_AcceleratedCompositingAllowed DISABLED_AcceleratedCompositingAllowed #else #define MAYBE_AcceleratedCompositingAllowed AcceleratedCompositingAllowed @@ -298,8 +300,13 @@ IN_PROC_BROWSER_TEST_F(WebGLTest, WebGLDisabled) { #define MultisamplingAllowed DISABLED_MultisamplingAllowed #endif IN_PROC_BROWSER_TEST_F(GpuFeatureTest, MultisamplingAllowed) { - EXPECT_FALSE(GpuDataManager::GetInstance()->IsFeatureBlacklisted( - gpu::GPU_FEATURE_TYPE_MULTISAMPLING)); + bool expect_blacklisted = false; + if (gpu::GPUTestBotConfig::GpuBlacklistedOnBot()) + expect_blacklisted = true; + + EXPECT_EQ(expect_blacklisted, + GpuDataManager::GetInstance()->IsFeatureBlacklisted( + gpu::GPU_FEATURE_TYPE_MULTISAMPLING)); // Multisampling is not supported if running on top of osmesa. if (gfx::GetGLImplementation() != gfx::kGLImplementationOSMesaGL) @@ -380,6 +387,9 @@ IN_PROC_BROWSER_TEST_F(GpuFeatureTest, Canvas2DAllowed) { expected_state = BLACKLISTED; #endif + if (gpu::GPUTestBotConfig::GpuBlacklistedOnBot()) + expected_state = BLACKLISTED; + #if defined(USE_AURA) // Canvas 2D is always disabled in software compositing mode, make sure it is // marked as such if it wasn't blacklisted already. @@ -434,6 +444,9 @@ IN_PROC_BROWSER_TEST_F(Canvas2DDisabledTest, Canvas2DDisabled) { IN_PROC_BROWSER_TEST_F(GpuFeatureTest, CanOpenPopupAndRenderWithWebGLCanvas) { + if (gpu::GPUTestBotConfig::GpuBlacklistedOnBot()) + return; + const base::FilePath url(FILE_PATH_LITERAL("webgl_popup.html")); RunTest(url, "\"SUCCESS\"", false); } @@ -508,6 +521,9 @@ IN_PROC_BROWSER_TEST_F(GpuFeatureTest, IOSurfaceReuse) { if (!IOSurfaceSupport::Initialize()) return; + if (gpu::GPUTestBotConfig::GpuBlacklistedOnBot()) + return; + const base::FilePath url( FILE_PATH_LITERAL("feature_compositing_static.html")); base::FilePath test_path = gpu_test_dir_.Append(url); diff --git a/chrome/test/ppapi/ppapi_browsertest.cc b/chrome/test/ppapi/ppapi_browsertest.cc index 6f4b8a3..840b2a2 100644 --- a/chrome/test/ppapi/ppapi_browsertest.cc +++ b/chrome/test/ppapi/ppapi_browsertest.cc @@ -306,6 +306,12 @@ TEST_PPAPI_NACL(Graphics2D_BindNull) #define MAYBE_OUT_Graphics3D Graphics3D #define MAYBE_NACL_Graphics3D DISABLED_Graphics3D #endif // defined(USE_AURA) +#elif defined(OS_MACOSX) +// These tests fail when using the legacy software mode. Reenable when the +// software compositor is enabled crbug.com/286038 +#define MAYBE_IN_Graphics3D DISABLED_Graphics3D +#define MAYBE_OUT_Graphics3D DISABLED_Graphics3D +#define MAYBE_NACL_Graphics3D DISABLED_Graphics3D #else // The tests are failing in-process. crbug.com/280282 #define MAYBE_IN_Graphics3D DISABLED_Graphics3D |