aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/RecordPatternTest.cpp
diff options
context:
space:
mode:
authorGravatar commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81>2014-05-06 21:32:19 +0000
committerGravatar commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81>2014-05-06 21:32:19 +0000
commit1b546462bb91e93cf2f033eb2dab53ec492b64ab (patch)
treefa6303ceea45f6e23e6ad272790b395c0e835300 /tests/RecordPatternTest.cpp
parent95b03ce59986ecee5e4188da630a563efca3afe8 (diff)
SaveLayer is not a draw.
Will keep thinking about the best way to handle this: - leave as-is - tag the records - some range check on T::kType - just list all Draw* in IsDraw BUG=skia:2378 R=fmalita@chromium.org, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/269543023 git-svn-id: http://skia.googlecode.com/svn/trunk@14602 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'tests/RecordPatternTest.cpp')
-rw-r--r--tests/RecordPatternTest.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/RecordPatternTest.cpp b/tests/RecordPatternTest.cpp
index e013150072..4f51bdba24 100644
--- a/tests/RecordPatternTest.cpp
+++ b/tests/RecordPatternTest.cpp
@@ -190,3 +190,13 @@ DEF_TEST(RecordPattern_Complex, r) {
REPORTER_ASSERT(r, !pattern.search(&record, &begin, &end));
}
+
+DEF_TEST(RecordPattern_SaveLayerIsNotADraw, r) {
+ Pattern1<IsDraw> pattern;
+
+ SkRecord record;
+ SkRecorder recorder(SkRecorder::kWriteOnly_Mode, &record, 1920, 1200);
+ recorder.saveLayer(NULL, NULL);
+
+ REPORTER_ASSERT(r, !pattern.match(&record, 0));
+}