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

MarkUsProject / Markus / 7950051800 / 1
92%
master: 92%

Build:
DEFAULT BRANCH: master
Ran 18 Feb 2024 04:03PM UTC
Files 551
Run time 10s
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

18 Feb 2024 03:42PM UTC coverage: 94.835% (+0.01%) from 94.825%
7950051800.1

push

github

web-flow
Section API-controller actions (#6955)

* actions-for-sections-api-controller

Added index, show, and update actions for the api controller of the sections model. I modified routes.rb (to actually establish the existence of these routes).

I realised that because of the MainApiController (which all the API controllers inherit), the SessionHandler.check_record method already ensures that an incoming request trying to do something with a particular record is valid (i.e. the record actually exists), so it would be redundant to check whether current_course.sections.find(params[:id]) for example returns a valid current_course.

* tests-for-section-api-controller

Added rspec tests for the update, index, and show actions of the api controller of sections. I tested both authorised and unauthorised requests, and for the GET requests (show and index), where either a json or xml response is expected, I tested that all necessary keys (corresponding to model attributes) are present, although I did not check whether the values of these attributes match between the responses and the original object data (not sure whether I should go this far). Also, for the #index request, some of my expectations perform an equality comparison between arrays; maybe it would be preferable to instead convert these to sets and make a comparison between sets.

37363 of 39398 relevant lines covered (94.83%)

105.07 hits per line

Source Files on job rspec - 7950051800.1
  • Tree
  • List 0
  • Changed 27
  • Source Changed 3
  • Coverage Changed 2
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 7950051800
  • bb75e14f on github
  • Prev Job for on master (#7938807998.1)
  • Next Job for on master (#8031400082.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