Database Testing / Quiz
Schemaless, Not Lawless
MongoDB and friends won't reject bad documents unless you make them. Validation, null-vs-missing, stale secondary reads, and denormalized drift.
- Difficulty
- Hard
- Format
- Quiz
- Points
- 200
- Estimate
- 11 min
// MISSION BRIEF
Your Mission
In a document store, the schema lives wherever you enforce it, which by default is nowhere. This quiz covers NoSQL validation for testers: schema-on-read consequences, the null/missing distinction, read consistency, unique indexes, and keeping denormalized copies honest.
Scoring: timed quiz; accuracy first, speed bonus for fast clean runs.
// FIRST CONTACT
Battle teaser
"Schema-on-read" means that by default, MongoDB will:
- AEnforce types but not field names
- BAccept any document shape; structure is only enforced if you add a $jsonSchema collection validator or validate in the application, both of which need tests
- CConvert documents to relational rows internally
- DReject documents that don't match the first inserted one
Answers, scoring, hints, and the full battle stay sealed.
// SKILL TAGS
nosqlmongodbdatabase-testingdata-validation