Fill: describe Block
Fill in the Blank Beginner
Question
Fill in the blank to group tests into a suite:
Code
___('MathUtils', () => {
test('adds correctly', () => {
expect(1 + 1).toBe(2);
});
});
Hint
The function for grouping tests is called describe.
Explanation
The correct answer is describe. describe(name, callback) creates a test suite that groups related test cases. The first argument is the suite name, and the second is a callback containing all the tests in the suite.
Related Resources
Related Lessons
- Test Structure
Organizing tests into suites and cases.
Look up unfamiliar terms
A beginner-friendly glossary explains jargon in plain English — variables, functions, DOM, Promise, and more.
Decode error messages
Plain-English explanations of common errors — what they mean, why they happen, and how to fix them.
Build real projects
Apply what you learned by building guided projects with starter code and solutions.