diff options
author | bsalomon <bsalomon@google.com> | 2016-04-05 12:59:06 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-04-05 12:59:06 -0700 |
commit | f2f1c17e331fe1e0ce695969970ecebc81e12ceb (patch) | |
tree | e4dc53ee03e1803307a43917fb440d19cfe3f6f1 /tests/TessellatingPathRendererTests.cpp | |
parent | 4319593988db5796023d9f5f34a8ed285c2097dd (diff) |
One signature for creating unit tests that run on premade GrContexts
GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1860593002
Review URL: https://codereview.chromium.org/1860593002
Diffstat (limited to 'tests/TessellatingPathRendererTests.cpp')
-rw-r--r-- | tests/TessellatingPathRendererTests.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/TessellatingPathRendererTests.cpp b/tests/TessellatingPathRendererTests.cpp index 6cf2a938dc..32973ee1c8 100644 --- a/tests/TessellatingPathRendererTests.cpp +++ b/tests/TessellatingPathRendererTests.cpp @@ -252,17 +252,18 @@ static void test_path(GrDrawTarget* dt, GrRenderTarget* rt, GrResourceProvider* tess.drawPath(args); } -DEF_GPUTEST_FOR_ALL_CONTEXTS(TessellatingPathRendererTests, reporter, context) { +DEF_GPUTEST_FOR_ALL_CONTEXTS(TessellatingPathRendererTests, reporter, ctxInfo) { GrSurfaceDesc desc; desc.fFlags = kRenderTarget_GrSurfaceFlag; desc.fWidth = 800; desc.fHeight = 800; desc.fConfig = kSkia8888_GrPixelConfig; desc.fOrigin = kTopLeft_GrSurfaceOrigin; - SkAutoTUnref<GrTexture> texture(context->textureProvider()->createApproxTexture(desc)); + SkAutoTUnref<GrTexture> texture( + ctxInfo.fGrContext->textureProvider()->createApproxTexture(desc)); GrTestTarget tt; GrRenderTarget* rt = texture->asRenderTarget(); - context->getTestTarget(&tt, rt); + ctxInfo.fGrContext->getTestTarget(&tt, rt); GrDrawTarget* dt = tt.target(); GrResourceProvider* rp = tt.resourceProvider(); |