code-review
Use to review code changes with a two-stage process - first checking spec/requirements…
Use when implementing new features or fixing bugs to enforce test-driven development. Guides the RED-GREEN-REFACTOR cycle for Java (JUnit), Python (pytest), and TypeScript (Jest/Playwright) in OpenMetadata.
$ npx -y skills add open-metadata/OpenMetadata --skill tdd --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/tddContext preview
The summary Claude sees to decide when to auto-load this skill.
Use when implementing new features or fixing bugs to enforce test-driven development. Guides the RED-GREEN-REFACTOR cycle for Java (JUnit), Python (pytest), and TypeScript (Jest/Playwright) in OpenMetadata.
name: tdd description: Use when implementing new features or fixing bugs to enforce test-driven development. Guides the RED-GREEN-REFACTOR cycle for Java (JUnit), Python (pytest), and TypeScript (Jest/Playwright) in OpenMetadata. user-invocable: true argument-hint: "<feature or bug description>"
Enforce RED-GREEN-REFACTOR discipline across all three language stacks.
Write the **smallest test** that describes the desired behavior. Run it. It **must fail**. If it passes, your test isn't testing the new behavior.
**Java (JUnit 5):**
# Write test in openmetadata-service/src/test/ or openmetadata-integration-tests/ mvn test -pl openmetadata-service -Dtest=YourTestClass#yourTestMethod
**Python (pytest):**
source env/bin/activate cd ingestion # Write test using pytest style — plain assert, no unittest.TestCase python -m pytest tests/unit/your_test.py::test_your_function -v
**TypeScript (Jest):**
cd openmetadata-ui/src/main/resources/ui yarn test path/to/YourComponent.test.ts
**Rules for RED:**
Write **only** the code needed to make the test pass. No more.
**Run the test again. It must pass.**
Now improve the code while keeping tests green:
# Java — format then test mvn spotless:apply mvn test -pl openmetadata-service # Python — format, lint, then test cd ingestion && make py_format && make py_format_check python -m pytest tests/unit/your_test.py -v # TypeScript — lint then test cd openmetadata-ui/src/main/resources/ui yarn lint:fix yarn test path/to/YourComponent.test.ts
Go back to RED with the next behavior. Each cycle should take minutes, not hours.
| Layer | Test Type | Location | Runner | |-------|-----------|----------|--------| | Java REST API | Integration | `openmetadata-integration-tests/` | `mvn verify` | | Java service logic | Unit | `openmetadata-service/src/test/` | `mvn test` | | Python connectors | Unit | `ingestion/tests/unit/` | `pytest` | | Python integration | Integration | `ingestion/tests/integration/` | `pytest` | | React components | Unit | Co-located `.test.ts` files | `yarn test` | | UI E2E flows | E2E | `playwright/e2e/` | `yarn playwright:run` |
**Java integration tests** use `BaseEntityIT` with `TestNamespace` for isolation and `OpenMetadataClient` for API calls. Prefer this over heavily mocked unit tests for API testing.
**Python connector tests** should test real behavior:
# Good: test the actual parsing logic
def test_parse_table_metadata():
raw = {"name": "users", "columns": [...]}
result = parse_table(raw)
assert result.name == "users"
assert len(result.columns) == 3
# Bad: mock everything and verify calls
def test_parse_table_metadata():
mock_client = MagicMock()
mock_client.get.return_value = {...}
# ... 20 lines of mock setup
verify(mock_client.get).called_once() # proves nothing**Frontend tests** should render components and assert on visible output:
// Good: test what the user sees
render(<MyComponent data={testData} />);
expect(screen.getByText('Expected Label')).toBeInTheDocument();
// Bad: test implementation details
expect(component.state.internalFlag).toBe(true);The Open Context Layer for Data and AI , OpenMetadata is the open platform for building trusted data context and business semantics for humans, AI assistants, and agents.
Repo: open-metadata/OpenMetadata
Use to review code changes with a two-stage process - first checking spec/requirements…
Deep reliability audit for OpenMetadata connectors — runs 7 investigation prompts (metadata,…
Build a new OpenMetadata connector from scratch — scaffold JSON Schema, Python boilerplate,…
Review an OpenMetadata connector against golden standards. Runs multi-agent analysis covering…
Load all OpenMetadata connector development standards into context. Use before building or…
Set up, verify, or repair a local OpenMetadata development environment on macOS or Linux.…