• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

hustcc / jest-canvas-mock / 180
100%

Build:
DEFAULT BRANCH: master
Ran 04 Dec 2020 06:39AM UTC
Jobs 6
Files 11
Run time 49min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

pending completion
180

push

travis-ci

web-flow
Fix(clip): delete clipping region with restore (#73)

@hustcc please release a patch version after this pull request to version 2.2.1. 

Thanks!

* Fix(clip): delete clipping region with restore

Previously, the restore() method would update its pointer to the previous
clipping region (stackIndex = n-1) in the stack without deleting the current
clipping region (stackIndex = n). This caused problems for future save() calls,
which would push a new clipping region onto the stack at location n+1 while
only incrementing stackIndex to n, thus referencing the wrong region.

This commit fixes the issue by deleting the current clipping region when
restore() is called. By doing this, we lose the ability to inspect old
clipping regions, but this is easy to change in the future if it is desired.

* Address PR comments

Tests have been combined and make better use of the afterEach snapshots.

* Remove excess checks in test

536 of 536 branches covered (100.0%)

Branch coverage included in aggregate %.

1 of 1 new or added line in 1 file covered. (100.0%)

1003 of 1003 relevant lines covered (100.0%)

313.53 hits per line

Jobs
ID Job ID Ran Files Coverage
1 180.1 04 Dec 2020 06:39AM UTC 0
100.0
Travis Job 180.1
2 180.2 04 Dec 2020 06:39AM UTC 0
100.0
Travis Job 180.2
3 180.3 04 Dec 2020 06:39AM UTC 0
100.0
Travis Job 180.3
4 180.4 04 Dec 2020 06:39AM UTC 0
100.0
Travis Job 180.4
5 180.5 04 Dec 2020 07:28AM UTC 0
100.0
Travis Job 180.5
6 180.6 04 Dec 2020 07:28AM UTC 0
100.0
Travis Job 180.6
Source Files on build 180
  • Tree
  • List 11
  • Changed 4
  • Source Changed 1
  • Coverage Changed 4
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Travis Build #180
  • c4d1fb29 on github
  • Prev Build on master (#175)
  • Next Build on master (#189)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc