Make SkPath::conservativelyContainsRect not assert on paths that begin with repeated moveTos

R=reed@google.com

Author: bsalomon@google.com

Review URL: https://chromiumcodereview.appspot.com/21565002

git-svn-id: http://skia.googlecode.com/svn/trunk@10484 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/tests/PathTest.cpp b/tests/PathTest.cpp
index 6c8f83e..e33c912 100644
--- a/tests/PathTest.cpp
+++ b/tests/PathTest.cpp
@@ -1161,6 +1161,18 @@
                                                                                 SkIntToScalar(200),
                                                                                 SkIntToScalar(20),
                                                                                 SkIntToScalar(5))));
+
+    // same as above path and first test but with an extra moveTo.
+    path.reset();
+    path.moveTo(100, 100);
+    path.moveTo(0, 0);
+    path.lineTo(SkIntToScalar(100), 0);
+    path.lineTo(0, SkIntToScalar(100));
+
+    REPORTER_ASSERT(reporter, path.conservativelyContainsRect(SkRect::MakeXYWH(SkIntToScalar(50), 0,
+                                                                               SkIntToScalar(10),
+                                                                               SkIntToScalar(10))));
+
 }
 
 // Simple isRect test is inline TestPath, below.