diff options
Diffstat (limited to 'tests/TestConfigParsing.cpp')
-rw-r--r-- | tests/TestConfigParsing.cpp | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/tests/TestConfigParsing.cpp b/tests/TestConfigParsing.cpp index df028153e2..c5f620f748 100644 --- a/tests/TestConfigParsing.cpp +++ b/tests/TestConfigParsing.cpp @@ -39,7 +39,6 @@ DEF_TEST(ParseConfigs_Gpu, reporter) { REPORTER_ASSERT(reporter, configs.count() == 1); REPORTER_ASSERT(reporter, configs[0]->getTag().equals("gl")); REPORTER_ASSERT(reporter, configs[0]->getViaParts().count() == 0); -#if SK_SUPPORT_GPU REPORTER_ASSERT(reporter, configs[0]->asConfigGpu()); REPORTER_ASSERT(reporter, configs[0]->asConfigGpu()->getContextType() == GrContextFactory::kGL_ContextType); @@ -50,7 +49,6 @@ DEF_TEST(ParseConfigs_Gpu, reporter) { REPORTER_ASSERT(reporter, configs[0]->asConfigGpu()->getColorSpace() == nullptr); REPORTER_ASSERT(reporter, configs[0]->asConfigGpu()->getSurfType() == SkCommandLineConfigGpu::SurfType::kDefault); -#endif } DEF_TEST(ParseConfigs_OutParam, reporter) { @@ -125,7 +123,6 @@ DEF_TEST(ParseConfigs_DefaultConfigs, reporter) { REPORTER_ASSERT(reporter, configs[i]->getTag().equals(config1[i])); REPORTER_ASSERT(reporter, configs[i]->getViaParts().count() == 0); } -#if SK_SUPPORT_GPU REPORTER_ASSERT(reporter, !configs[0]->asConfigGpu()); REPORTER_ASSERT(reporter, !configs[1]->asConfigGpu()); REPORTER_ASSERT(reporter, configs[2]->asConfigGpu()); @@ -197,7 +194,6 @@ DEF_TEST(ParseConfigs_DefaultConfigs, reporter) { REPORTER_ASSERT(reporter, configs[36]->asConfigGpu()); REPORTER_ASSERT(reporter, configs[36]->asConfigGpu()->getSurfType() == SkCommandLineConfigGpu::SurfType::kBackendRenderTarget); -#endif } DEF_TEST(ParseConfigs_ExtendedGpuConfigsCorrect, reporter) { @@ -220,7 +216,6 @@ DEF_TEST(ParseConfigs_ExtendedGpuConfigsCorrect, reporter) { for (int i = 0; i < config1.count(); ++i) { REPORTER_ASSERT(reporter, configs[i]->getTag().equals(config1[i])); } -#if SK_SUPPORT_GPU REPORTER_ASSERT(reporter, configs[0]->asConfigGpu()->getContextType() == GrContextFactory::kGL_ContextType); REPORTER_ASSERT(reporter, configs[0]->asConfigGpu()->getUseNVPR()); @@ -263,7 +258,6 @@ DEF_TEST(ParseConfigs_ExtendedGpuConfigsCorrect, reporter) { GrContextFactory::kMock_ContextType); REPORTER_ASSERT(reporter, configs[9]->asConfigGpu()->getSurfType() == SkCommandLineConfigGpu::SurfType::kBackendTexture); -#endif } DEF_TEST(ParseConfigs_ExtendedGpuConfigsIncorrect, reporter) { @@ -290,9 +284,7 @@ DEF_TEST(ParseConfigs_ExtendedGpuConfigsIncorrect, reporter) { for (int i = 0; i < config1.count(); ++i) { REPORTER_ASSERT(reporter, configs[i]->getTag().equals(config1[i])); REPORTER_ASSERT(reporter, configs[i]->getBackend().equals(config1[i])); -#if SK_SUPPORT_GPU REPORTER_ASSERT(reporter, !configs[i]->asConfigGpu()); -#endif } } @@ -309,16 +301,11 @@ DEF_TEST(ParseConfigs_ExtendedGpuConfigsSurprises, reporter) { REPORTER_ASSERT(reporter, configs.count() == config1.count()); for (int i = 0; i < config1.count(); ++i) { REPORTER_ASSERT(reporter, configs[i]->getTag().equals(config1[i])); -#if SK_SUPPORT_GPU REPORTER_ASSERT(reporter, configs[i]->getBackend().equals("gpu")); REPORTER_ASSERT(reporter, configs[i]->asConfigGpu()); -#else - REPORTER_ASSERT(reporter, configs[i]->getBackend().equals(config1[i])); -#endif } } -#if SK_SUPPORT_GPU DEF_TEST(ParseConfigs_ViaParsing, reporter) { SkCommandLineFlags::StringArray config1 = make_string_array({ "a-b-c-8888", @@ -349,7 +336,6 @@ DEF_TEST(ParseConfigs_ViaParsing, reporter) { } } } -#endif DEF_TEST(ParseConfigs_ViaParsingExtendedForm, reporter) { SkCommandLineFlags::StringArray config1 = make_string_array({ @@ -365,13 +351,8 @@ DEF_TEST(ParseConfigs_ViaParsingExtendedForm, reporter) { const char* backend; const char* vias[3]; } expectedConfigs[] = { -#if SK_SUPPORT_GPU {"gpu", {"zz", "qq", nullptr}}, {"gpu", {"abc", "nbc", "cbs"}}, -#else - {"gpu[api=gles]", {"zz", "qq", nullptr}}, - {"gpu[api=angle_d3d9_es2,samples=1]", {"abc", "nbc", "cbs"}}, -#endif {"gpu[api=gl", {"a", nullptr, nullptr}}, // Missing bracket makes this is not extended // form but via still works as expected. {"angle_gl_es2[api=gles]", {"abc", "def", nullptr}} // This is not extended form. @@ -391,10 +372,8 @@ DEF_TEST(ParseConfigs_ViaParsingExtendedForm, reporter) { configs[i]->getViaParts()[j].equals(expectedConfigs[i].vias[j])); } } -#if SK_SUPPORT_GPU REPORTER_ASSERT(reporter, configs[0]->asConfigGpu()); REPORTER_ASSERT(reporter, configs[1]->asConfigGpu()); REPORTER_ASSERT(reporter, !configs[2]->asConfigGpu()); REPORTER_ASSERT(reporter, !configs[3]->asConfigGpu()); -#endif } |