oss-slu / oss-slu/DigitalBoneBox

Test `/combined-data` endpoint

Open
#264 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

back-end enhancement good first issue tests
Dominant language
JavaScript
Stars
8
Forks
18
Avg merge
8h 17m
Merged PRs (30d)
4

Description

🎯 Goal / Objective

A clear and concise description of what this task aims to achieve. Why is this task important?

Write unit tests for the /combined-data endpoint in server.js.


✅ Tasks to be Completed

A checklist of the specific, actionable steps required to complete this issue. This helps track progress.

  • Test that a successful data fetch returns status 200 and expected data type
  • Test that any inputs into the endpoint are properly validated
  • Test that bad inputs return status 400
  • Test that trying to fetch non-existent data returns status 404
  • The above steps are just a place to get started. Test for more edge cases and possible inputs/outputs than the steps listed here.
  • Fix any errors that failed tests expose.

Acceptance Criteria

A checklist of conditions that must be met for this task to be considered complete. How will we verify that it's done correctly?

  • The new feature is implemented as described.
  • All related code passes the repository's workflow checks (linting, tests).
  • The application runs without errors after the changes are made.

Additional Context

Add any other context, notes, screenshots, or links that might be helpful for completing this task.

#263 is a prerequisite. See the parent issue for more information.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Read issue #263 first, then inspect the /combined-data endpoint in server.js to identify its inputs, successful response, validation, and not-found behavior. Add tests covering the listed 200, 400, and 404 cases plus relevant edge cases, and finish when the repository workflow checks pass without application errors.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, nodejs
Domain
api, backend, testing
Issue type
Refactor
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
43/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.