/odoo-skills:odoo-test-writerfrom odoo-skills
Creates and improves Odoo custom module tests using TransactionCase, HttpCase, Form helper, and mock patching for external APIs.
Ships in odoo-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Use this skill to add practical tests for Odoo custom modules. Prefer tests at the Odoo behavior seam: ORM flows, constraints, computes, access rules, controllers, reports, forms, workflows, and integration boundaries.
Before writing tests:
__manifest__.py, models/, views/, security/, controllers/, report/, static/src/, existing tests/, and relevant docs.$ODOO_SOURCE is set, inspect local test helpers and framework behavior instead of guessing.TransactionCase for most model/business-logic tests. Each test runs in a savepoint and rolls back.AccountTestInvoicingCommon for accounting tests needing companies, products, partners, taxes, journals, or invoices.Form helper when testing default values, onchanges, form validations, One2many/Many2many form behavior, or user-like form flows.HttpCase for browser, tour, website, portal, controller, or full UI flows.SingleTransactionCase only for read-only suites or expensive setup where cross-test state is acceptable.unittest.mock.patch/MagicMock for external APIs, payment gateways, OAuth, webhooks, file system, time, or slow services. Do not mock Odoo internals unless there is no better seam.your_module/
├── __init__.py # Do not import tests here
├── __manifest__.py
├── tests/
│ ├── __init__.py # Import test modules here
│ ├── common.py # Optional shared fixtures/helpers
│ └── test_*.py # Test files
Every new test_*.py must be imported from tests/__init__.py, or the Odoo test runner will not discover it.
tests/common.py only for reusable fixtures/helpers.setUpClass.with_user().assertQueryCount when supported by the target version/test base.tests/__init__.py and manifest dependencies only when evidence requires it.odoo-web-testing and its OWL-TESTING.md reference.Default pattern for post-install module tests:
from odoo.tests import tagged
@tagged("post_install", "-at_install")
class TestYourFeature(YourModuleTestCommon):
pass
odoo-code-tracer when you need to trace the behavior before writing tests.odoo-code-review when reviewing test coverage or test quality.What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
odoo-testing, transactioncase, httpcase, odoo-forms, mock-external-apis
Generated from the plugin's indexed repository (mart337i/odoo-skills) — no native marketplace selected
npx claudepluginhub p/mart337i-odoo-skills21 skills in this plugin
/grill-meInterview the user relentlessly about a plan or design until reaching shared understanding, resolving each branch of the decision tree. Use when the user wants to stress-test a plan, get grilled on their design, or mentions "grill me" outside an Odoo-specific context./grill-with-docsGrilling session that challenges your plan against the existing domain model, sharpens terminology, and updates documentation (CONTEXT.md, ADRs) inline as decisions crystallise. Use when the user wants to stress-test a plan against their project's language and documented decisions./improve-codebase-architectureFind deepening opportunities in a codebase, informed by the domain language in CONTEXT.md and the decisions in docs/adr/. Use when the user wants to improve architecture, find refactoring opportunities, consolidate tightly-coupled modules, or make a codebase more testable and AI-navigable./odooOdoo engineering workflows for addon development, codebase exploration, debugging, architecture/refactor review, manifest/docs sync, and routing to migration work. Use when the user mentions Odoo, addons, modules, manifests, models, XML views, security CSVs, record rules, Odoo shell, OWL/QWeb/assets, or when an Odoo codebase is detected./odoo-17.0Odoo 17 development reference for Python models and ORM (search, domain, read_group, compute fields), XML/CSV data and views, OWL/JS client code, QWeb reports, security (ACL, record rules, groups), cron and server actions, migrations and module upgrades, tests, i18n, and performance. Use this skill whenever work involves Odoo 17 or custom addons, including traceback diagnosis, addons, manifests, XML errors, HTTP controllers, business rules, feature work, refactoring, or reviews./odoo-18.0Odoo 18 development reference for Python models and ORM (search, domain, read_group, compute fields), XML/CSV data and views, OWL/JS client code, QWeb reports, security (ACL, record rules, groups), cron and server actions, migrations and module upgrades, tests, i18n, and performance. Use this skill whenever work involves Odoo 18 or custom addons, including traceback diagnosis, addons, manifests, XML errors, HTTP controllers, business rules, feature work, refactoring, or reviews.Other plugins' skills for the same job