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

kobotoolbox / kpi / 14708226741 / 2
81%
master: 76%

Build:
Build:
LAST BUILD BRANCH: dev-1257-remove-v1-forms-endpoint
DEFAULT BRANCH: master
Ran 28 Apr 2025 01:28PM UTC
Files 651
Run time 20s
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

28 Apr 2025 12:50PM UTC coverage: 80.786% (+2.1%) from 78.67%
14708226741.2

push

github

web-flow
test: add query-counting tests to critical endpoints (#5696)

### 💭 Notes
Add query-counting tests to the following endpoints:

/assets - AssetViewSet (v1), tested in v1/test_api_assets.py
/api/v2/assets/*uid*/data - DataViewSet, tested in test_data_viewset.py
/api/v2/assets - AssetViewSet, tested in v2/test_api_assets.py
/assets/*uid*/submissions - SubmissionViewSet, tested in
v1/test_api_submissions.py
/*username*/submission - XFormSubmissionApi, tested in
test_xform_submission_api.py

Adding these tests revealed that we were in fact hitting the database
once per asset to get export settings, so this PR also adds
export_settings to the prefetched attributes, and replaces the
serializer method field with the built-in django nested serializer.

### Preview Steps
1. Have an account and a project
2. Make sure the project has at least one select-one question
3. Add a few submissions to the project
4. Go to Data -> Downloads
5. Open Advanced Settings and check 'Save selection'
6. Export the data (you won't actually need the exported data)
7. [on main] go to `api/v2/assets` and take note of what is in the
export_settings field of your project
8. [on main] go to `api/v2/assets/<asset_uid>` and similarly take note
of what is in the export_settings field
9. [on branch] go to the same 2 endpoints and make sure the
export_settings are the same

6192 of 9847 branches covered (62.88%)

23495 of 29083 relevant lines covered (80.79%)

0.81 hits per line

Source Files on job 14708226741.2
  • Tree
  • List 651
  • Changed 21
  • Source Changed 0
  • Coverage Changed 21
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Build 14708226741
  • 56a2c9a9 on github
  • Prev Job for on main (#14707759704.1)
  • Next Job for on main (#14732544675.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