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

OpenBuildings / purchases / 129
99%

Build:
DEFAULT BRANCH: master
Ran 14 Nov 2013 09:11PM UTC
Jobs 1
Files 44
Run time –
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
129

push

travis-ci

hkdobrev
Use STI instead of type for purchase_items

Using single-table inheritance(STI) allows us to define different models
for the different types of purchase items. Each model could have
a different way of computing the price.

Filtering by type is kept the same using `Model_Purchase_Item::type()`.

Breaking changes:
 - `purchase_items`.`type` column is removed from db schema
 - `purchase_items`.`model` column is added to db schema
 - `Model_Purchase_Item::compute_price()` uses `get_price()` to.
 - `Model_Purchase_Item_Product` is introduced. It extends `Model_Purchase_Item`
   and overrides `get_price()`.
 - New types of purchases items should be implemented using STI and creating new models.

602 of 625 relevant lines covered (96.32%)

1.22 hits per line

Jobs
ID Job ID Ran Files Coverage
1 129.1 14 Nov 2013 09:09PM UTC 0
96.32
Travis Job 129.1
Source Files on build 129
Detailed source file information is not available for this build.
  • Back to Repo
  • Travis Build #129
  • b99d0a8e on github
  • Prev Build on master (#127)
  • Next Build on master (#131)
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