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

MediaComem / biopocket-backend / 37 / 1
86%
master: 92%

Build:
Build:
LAST BUILD BRANCH: story-2-user-registration
DEFAULT BRANCH: master
Ran 11 Dec 2017 01:40PM UTC
Files 37
Run time 1s
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

11 Dec 2017 01:37PM UTC coverage: 85.781%. Remained the same
NODE_ENV=test SESSION_SECRET=travis

push

travis-ci

AlphaHydrae
Implement POST /api/locations route

A migration was necessary to fix the type of the `locations` table's
`geometry` column, which is now a PostGIS geometry column instead of a
PostgreSQL point.

The new `bookshelf-geojson` dependency handles serializing and
deserializing GeoJSON columns when communicating with PostgreSQL through
Bookshelf.

The new `knex-postgis` dependency was added to avoid issues with
`returning *` in SQL queries returning locations. For the
`bookshelf-geojson` library to be able to parse the location's geometry,
it must be transformed first with `knex-postgis`'s `st.asGeoJSON`
function.

New validators have been added to validate a GeoJSON point (i.e. the
location's `geometry` property).

The workaround that was implemented in `server/models/abstract.js` has
been encapsulated into a Bookshelf plugin and moved to
`server/utils/bookshelf-returning.js`. Ideally, the fix should be made
in Bookshelf itself as a pull request.

The two new Abstract model `parseFrom` and `serializeTo` methods are
shortcuts to parse JSON data into a model's columns, and to serialize a
model's column to JSON. They handle the conversion to and from
underscore and camel-case (using the new `inflection` dependency), and
simplify parsing/serializing deep objects.

Story: TG-43
Tasks: TG-88 TG-89 TG-92

234 of 333 branches covered (70.27%)

Branch coverage included in aggregate %.

864 of 947 relevant lines covered (91.24%)

6.2 hits per line

Source Files on job 37.1 (NODE_ENV=test SESSION_SECRET=travis)
  • Tree
  • List 0
  • Changed 0
  • Source Changed 0
  • Coverage Changed 0
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Build 37
  • Travis Job 37.1
  • bea3e70b on github
  • Prev Job for NODE_ENV=test SESSION_SECRET=travis on task-locations-crud-create (#36.1)
  • Next Job for NODE_ENV=test SESSION_SECRET=travis on task-locations-crud-create (#41.1)
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