aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--tests/GLProgramsTest.cpp2
-rw-r--r--tests/ImageFilterTest.cpp22
-rw-r--r--tests/ImageTest.cpp8
-rw-r--r--tests/ReadPixelsTest.cpp2
-rw-r--r--tests/Test.h2
-rw-r--r--tests/TestTest.cpp10
6 files changed, 17 insertions, 29 deletions
diff --git a/tests/GLProgramsTest.cpp b/tests/GLProgramsTest.cpp
index 57274e0678..52d1e0375c 100644
--- a/tests/GLProgramsTest.cpp
+++ b/tests/GLProgramsTest.cpp
@@ -331,7 +331,7 @@ bool GrDrawingManager::ProgramUnitTest(GrContext* context, int maxStages) {
GrClip clip;
SkRandom random;
- static const int NUM_TESTS = 2048;
+ static const int NUM_TESTS = 1024;
for (int t = 0; t < NUM_TESTS; t++) {
// setup random render target(can fail)
SkAutoTUnref<GrRenderTarget> rt(random_render_target(
diff --git a/tests/ImageFilterTest.cpp b/tests/ImageFilterTest.cpp
index 58dc1a7161..49455c9481 100644
--- a/tests/ImageFilterTest.cpp
+++ b/tests/ImageFilterTest.cpp
@@ -652,7 +652,7 @@ DEF_TEST(TestNegativeBlurSigma, reporter) {
}
#if SK_SUPPORT_GPU
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(TestNegativeBlurSigma_Gpu, reporter, context) {
+DEF_GPUTEST_FOR_RENDERING_CONTEXTS(TestNegativeBlurSigma_Gpu, reporter, context) {
run_gpu_test(reporter, context, 100, test_negative_blur_sigma);
}
#endif
@@ -698,7 +698,7 @@ DEF_TEST(TestZeroBlurSigma, reporter) {
}
#if SK_SUPPORT_GPU
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(TestZeroBlurSigma_Gpu, reporter, context) {
+DEF_GPUTEST_FOR_RENDERING_CONTEXTS(TestZeroBlurSigma_Gpu, reporter, context) {
run_gpu_test(reporter, context, 100, test_zero_blur_sigma);
}
#endif
@@ -732,7 +732,7 @@ DEF_TEST(ImageFilterFailAffectsTransparentBlack, reporter) {
}
#if SK_SUPPORT_GPU
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(ImageFilterFailAffectsTransparentBlack_Gpu, reporter, context) {
+DEF_GPUTEST_FOR_RENDERING_CONTEXTS(ImageFilterFailAffectsTransparentBlack_Gpu, reporter, context) {
run_gpu_test(reporter, context, 100, test_fail_affects_transparent_black);
}
#endif
@@ -946,7 +946,7 @@ DEF_TEST(ImageFilterMergeResultSize, reporter) {
}
#if SK_SUPPORT_GPU
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(ImageFilterMergeResultSize_Gpu, reporter, context) {
+DEF_GPUTEST_FOR_RENDERING_CONTEXTS(ImageFilterMergeResultSize_Gpu, reporter, context) {
run_gpu_test(reporter, context, 100, test_imagefilter_merge_result_size);
}
#endif
@@ -1081,7 +1081,7 @@ DEF_TEST(ImageFilterCropRect, reporter) {
}
#if SK_SUPPORT_GPU
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(ImageFilterCropRect_Gpu, reporter, context) {
+DEF_GPUTEST_FOR_RENDERING_CONTEXTS(ImageFilterCropRect_Gpu, reporter, context) {
run_gpu_test(reporter, context, 100, test_crop_rects);
}
#endif
@@ -1204,7 +1204,7 @@ DEF_TEST(ImageFilterClippedPictureImageFilter, reporter) {
}
#if SK_SUPPORT_GPU
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(ImageFilterClippedPictureImageFilter_Gpu, reporter, context) {
+DEF_GPUTEST_FOR_RENDERING_CONTEXTS(ImageFilterClippedPictureImageFilter_Gpu, reporter, context) {
run_gpu_test(reporter, context, 2, test_clipped_picture_imagefilter);
}
#endif
@@ -1456,7 +1456,7 @@ DEF_TEST(ComposedImageFilterOffset, reporter) {
}
#if SK_SUPPORT_GPU
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(ComposedImageFilterOffset_Gpu, reporter, context) {
+DEF_GPUTEST_FOR_RENDERING_CONTEXTS(ComposedImageFilterOffset_Gpu, reporter, context) {
run_gpu_test(reporter, context, 100, test_composed_imagefilter_offset);
}
#endif
@@ -1500,7 +1500,7 @@ DEF_TEST(ComposedImageFilterBounds, reporter) {
}
#if SK_SUPPORT_GPU
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(ComposedImageFilterBounds_Gpu, reporter, context) {
+DEF_GPUTEST_FOR_RENDERING_CONTEXTS(ComposedImageFilterBounds_Gpu, reporter, context) {
run_gpu_test(reporter, context, 100, test_composed_imagefilter_bounds);
}
#endif
@@ -1530,7 +1530,7 @@ DEF_TEST(PartialCropRect, reporter) {
}
#if SK_SUPPORT_GPU
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(PartialCropRect_Gpu, reporter, context) {
+DEF_GPUTEST_FOR_RENDERING_CONTEXTS(PartialCropRect_Gpu, reporter, context) {
run_gpu_test(reporter, context, 100, test_partial_crop_rect);
}
#endif
@@ -1666,7 +1666,7 @@ DEF_TEST(BlurLargeImage, reporter) {
#if SK_SUPPORT_GPU
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(HugeBlurImageFilter_Gpu, reporter, context) {
+DEF_GPUTEST_FOR_RENDERING_CONTEXTS(HugeBlurImageFilter_Gpu, reporter, context) {
const SkSurfaceProps props(SkSurfaceProps::kLegacyFontHost_InitType);
SkAutoTUnref<SkGpuDevice> device(SkGpuDevice::Create(context,
@@ -1680,7 +1680,7 @@ DEF_GPUTEST_FOR_NATIVE_CONTEXT(HugeBlurImageFilter_Gpu, reporter, context) {
test_huge_blur(&canvas, reporter);
}
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(XfermodeImageFilterCroppedInput_Gpu, reporter, context) {
+DEF_GPUTEST_FOR_RENDERING_CONTEXTS(XfermodeImageFilterCroppedInput_Gpu, reporter, context) {
const SkSurfaceProps props(SkSurfaceProps::kLegacyFontHost_InitType);
SkAutoTUnref<SkGpuDevice> device(SkGpuDevice::Create(context,
diff --git a/tests/ImageTest.cpp b/tests/ImageTest.cpp
index 8485fdad68..96bc48e711 100644
--- a/tests/ImageTest.cpp
+++ b/tests/ImageTest.cpp
@@ -369,7 +369,7 @@ DEF_TEST(image_newfrombitmap, reporter) {
* but we don't have that facility (at the moment) so we use a little internal knowledge
* of *how* the raster version is cached, and look for that.
*/
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(SkImage_Gpu2Cpu, reporter, context) {
+DEF_GPUTEST_FOR_RENDERING_CONTEXTS(SkImage_Gpu2Cpu, reporter, context) {
SkImageInfo info = SkImageInfo::MakeN32(20, 20, kOpaque_SkAlphaType);
sk_sp<SkImage> image(create_gpu_image(context));
const uint32_t uniqueID = image->uniqueID();
@@ -404,7 +404,7 @@ DEF_GPUTEST_FOR_NATIVE_CONTEXT(SkImage_Gpu2Cpu, reporter, context) {
}
}
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(SkImage_newTextureImage, reporter, context, glContext) {
+DEF_GPUTEST_FOR_RENDERING_CONTEXTS(SkImage_newTextureImage, reporter, context, glContext) {
GrContextFactory otherFactory;
GrContextFactory::ContextInfo otherContextInfo =
otherFactory.getContextInfo(GrContextFactory::kNative_GLContextType);
@@ -701,7 +701,7 @@ static void check_image_color(skiatest::Reporter* reporter, SkImage* image, SkPM
REPORTER_ASSERT(reporter, image->readPixels(info, &pixel, sizeof(pixel), 0, 0));
REPORTER_ASSERT(reporter, pixel == expected);
}
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(SkImage_NewFromTexture, reporter, context) {
+DEF_GPUTEST_FOR_RENDERING_CONTEXTS(SkImage_NewFromTexture, reporter, context) {
GrTextureProvider* provider = context->textureProvider();
const int w = 10;
const int h = 10;
@@ -820,7 +820,7 @@ DEF_GPUTEST_FOR_RENDERING_CONTEXTS(NewTextureFromPixmap, reporter, context) {
}
}
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(DeferredTextureImage, reporter, context, glContext) {
+DEF_GPUTEST_FOR_RENDERING_CONTEXTS(DeferredTextureImage, reporter, context, glContext) {
SkAutoTUnref<GrContextThreadSafeProxy> proxy(context->threadSafeProxy());
GrContextFactory otherFactory;
diff --git a/tests/ReadPixelsTest.cpp b/tests/ReadPixelsTest.cpp
index e6552108b5..15aede559d 100644
--- a/tests/ReadPixelsTest.cpp
+++ b/tests/ReadPixelsTest.cpp
@@ -576,7 +576,7 @@ static void dump_to_file(const char name[], SkData* data) {
*
* https://bug.skia.org/4351
*/
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(ReadPixels_Subset_Gpu, reporter, context) {
+DEF_GPUTEST_FOR_RENDERING_CONTEXTS(ReadPixels_Subset_Gpu, reporter, context) {
SkBitmap bitmap;
make_ringed_bitmap(&bitmap, 6, 6);
const SkIRect subset = SkIRect::MakeLTRB(2, 2, 4, 4);
diff --git a/tests/Test.h b/tests/Test.h
index 7660c44d0d..7430372e7d 100644
--- a/tests/Test.h
+++ b/tests/Test.h
@@ -173,8 +173,6 @@ private:
DEF_GPUTEST_FOR_CONTEXTS(name, skiatest::kAllRendering_GPUTestContexts, reporter, __VA_ARGS__)
#define DEF_GPUTEST_FOR_NULL_CONTEXT(name, reporter, ...) \
DEF_GPUTEST_FOR_CONTEXTS(name, skiatest::kNull_GPUTestContexts, reporter, __VA_ARGS__)
-#define DEF_GPUTEST_FOR_NATIVE_CONTEXT(name, reporter, ...) \
- DEF_GPUTEST_FOR_CONTEXTS(name, skiatest::kNative_GPUTestContexts, reporter, __VA_ARGS__)
#define REQUIRE_PDF_DOCUMENT(TEST_NAME, REPORTER) \
do { \
diff --git a/tests/TestTest.cpp b/tests/TestTest.cpp
index d72e02d5c1..66c9b2df5c 100644
--- a/tests/TestTest.cpp
+++ b/tests/TestTest.cpp
@@ -44,16 +44,6 @@ DEF_GPUTEST_FOR_RENDERING_CONTEXTS(TestGpuRenderingContexts, reporter, context)
}
#endif
-// This is an example of a GPU test that tests a property that should work at least for the native
-// GPU context. If the test takes a long time to run, it may be appropriate to test only the native
-// context.
-#if SK_SUPPORT_GPU
-DEF_GPUTEST_FOR_NATIVE_CONTEXT(TestGpuNativeContext, reporter, context) {
- REPORTER_ASSERT(reporter, reporter);
- REPORTER_ASSERT(reporter, context);
-}
-#endif
-
// This is an example of a GPU test that tests a property that uses the null GPU context. It should
// be used if the test tests some behavior that is mocked with the null context.
#if SK_SUPPORT_GPU