IT Japanese · Testing & Quality Assurance
What does モック mean in Japanese?
Mock object / mock
| Terms | モック |
|---|---|
| Reading | モック |
| English Meaning | Mock object / mock |
| Level | Common |
| Specialty Area | Testing & Quality Assurance |
| Specialty | IT Japanese |
Technical Explanation
A simulated test double that stands in for dependencies required by code under test (external APIs, databases, email services): returning predefined responses while recording invocation interactions. Mocks enable unit tests to run swiftly without relying on external system states.
Practical Notes
In design meetings, モック frequently designates a UI mockup. In strict testing terminology, while a stub (スタブ) merely returns fixed values, a mock also verifies that calls occurred as expected, though many teams use both terms interchangeably.
Workplace Examples
外部APIはモックにして、単体テストを書いてください。
Please mock the external API and author unit tests.
モックのレスポンスが本物と違っていたので、結合テストで不具合が出ました。
Because the mock's response differed from the real service, defects surfaced during integration testing.