Practice assignment
Spring Boot coding challenge example
- Spring Boot 3
- Java 21
- 3-hour timebox
- vs LeetCode
Search results for “Spring Boot coding challenge” or “Spring Boot coding test” often mix algorithm sites with take-homes. They are not the same exercise. A HireCheck Spring Boot challenge is a service you can run: mvn verify starts red, the README is the contract, and a reviewer will read your NOTES.md.
The starter
The free sample is a securities trade-file import (company name removed from the posting it was generated from):
$ mvn verify [ERROR] Tests run: 55, Failures: 0, Errors: 55, Skipped: 0 [INFO] BUILD FAILURE
That red suite is intentional. Your job is to implement TradeImportService.importCsv until it is green, then add a few tests and NOTES.md.
Requirements
What “done in 3 hours” usually means
- The provided tests pass. This is the bar for “junior” if the rest is messy, and a prerequisite for everything else.
- The error contract is right —
{code, message}, not an uncaught exception. - You have two or three of your own tests (a CRLF file, a duplicate, an inverted date range, a 404 path).
- NOTES.md records a decision you postponed (Spring Batch, ISIN checksum, async jobs, indexes).
Other Spring Boot challenges in this library, if you want more than an import: orders API, JWT notes API, FX client, JPA reporting, Postgres holds.
Grading rubric
The sample import uses this rubric (100 points):
| Area | Points |
|---|---|
| Correctness (provided tests) | 30 |
| Validation completeness and clear reasons | 15 |
| Streaming / memory for large files | 15 |
| Own tests | 15 |
| Transaction strategy, justified | 10 |
| NOTES.md | 15 |
Levels: junior ≥ 60, mid ≥ 75, senior ≥ 85 (and a strong NOTES.md).
What reviewers look for
- Did you treat the tests as the specification, or argue with them in comments?
- Is the project still a Maven project a reviewer can clone and run in one command?
- Did you spend the last 40 minutes on NOTES.md and two extra tests, or on renaming packages?
- Would a reviewer be able to tell mid from senior without opening every file? That is usually the notes and the extra tests.
Common mistakes
- Starting from a blank Spring Initializr and missing the timebox, when the employer (or this practice task) already gave you a starter.
- Rewriting the test suite so it matches your API, instead of the other way around.
- Preparing only LeetCode. A Spring challenge will not ask you to invert a binary tree; it will ask you to not lose a row, a pound, or a retry.
- Leaving
TODOmarkers andUnsupportedOperationExceptionin a submission you think is finished.
How to run it
Download the sample, run mvn verify, and work the TODOs. No account required. When you have a real posting open, paste it and generate a fresh starter.
Download the 3-hour Spring Boot sample (no account), or generate a challenge from a job ad you have open.
Download the Spring Boot sample ZIP Generate one from a job adRelated practice tasks
Frequently asked questions
- Is a Spring Boot coding test the same as a take-home?
- Often yes: a 2–4 hour service with tests. Sometimes 'coding test' means a timed algorithm site. Read the invitation. This page is about the take-home kind.
- How strict is the 3-hour timebox?
- Treat it as real. A mid-level reviewer would rather see a green suite and honest notes than a half-finished rewrite of the architecture.
- Do I need an account for the sample?
- No. The ZIP is on this page. Generating a new assignment from a job posting needs a free account.
Practice only. This is an original HireCheck practice assignment, not a real employer's take-home, and it is not affiliated with any company mentioned as a role example.