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

hypothesis / h / 8922
70%
master: 97%

Build:
Build:
LAST BUILD BRANCH: realtime-update-v1-h-only-1
DEFAULT BRANCH: master
Ran 30 Oct 2015 03:05PM UTC
Jobs 1
Files 88
Run time 15s
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
8922

push

travis-ci

seanh
Add AnnotationHTMLPresenter

This splits h.api.models.Annotation into two classes:

1. h.api.models.Annotation, which contains only model code and no presentation
   code.

   This _does_ contain code for papering over the variability of our annotation
   data. For example it has a .uri property that always returns a unicode
   string even if the underlying annotation dict has no "uri" key or has a key
   whose value isn't a string.

2. h.AnnotationHTMLPresenter, a wrapper class for h.api.models.Annotation that:

   a. Overrides some properties with HTML-specific behaviour.
      For example it overrides .uri to provide an HTML-escaped copy.

   b. Adds some new HTML-specific properties. For example it adds a
      .document_link property that returns an escaped, HTML-formatted link
      for the annotation's document.

Many Annotation tests are now moved to AnnotationHTMLPresenter tests.

feed/atom.py, feeds/rss.py and groups/views.py are updated to use
AnnotationHTMLPresenter.

Tests for these modules need to be updated to mock AnnotationHTMLPresenter
behaviour, which is unfortunately quite awkward and requires a mock class.

2607 of 3749 relevant lines covered (69.54%)

0.7 hits per line

Jobs
ID Job ID Ran Files Coverage
1 8922.1 30 Oct 2015 03:05PM UTC 0
69.54
Travis Job 8922.1
Source Files on build 8922
Detailed source file information is not available for this build.
  • Back to Repo
  • Travis Build #8922
  • 0378f0e6 on github
  • Prev Build on annotation-html-presenter (#8920)
  • Next Build on annotation-html-presenter (#8959)
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

© 2026 Coveralls, Inc