tester

A testing role for Python projects, with guidance on test coverage, mocks, fixtures, and conditional test setup. It includes project-specific practices for testing PyMAPDL, a Python library that connects to the MAPDL engineering solver.

In plain words
What is it for?
Use it to write or review Python tests, mock external services, investigate flaky tests, and run tests only in suitable local, remote, or platform environments.
Why use it?
It helps improve test coverage and reliability while avoiding unnecessary launches of expensive MAPDL instances.

Agent

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/ansys/pymapdl/tester
Clone the repo
git clone --depth 1 https://github.com/ansys/pymapdl
Per session 37 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 598 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00037 $0.00598
Opus 5 $0.00018 $0.00299
Sonnet 5 $0.00007 $0.00120
Haiku 4.5 $0.00004 $0.00060

Measured 2d ago against content hash c3eb9c6413c8, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

tester scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.github/agents/tester.agent.md · 87 lines

How it starts

The opening of the file, as written. The whole thing — 87 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Test Engineer Agent

Coverage target

Minimum 90% — run with:

uv run pytest --cov=src/ansys/mapdl/core --cov-report=term

MAPDL instances are expensive — mock whenever possible

from unittest.mock import Mock


def test_feature_without_mapdl():
    expected_value = object()
    mock_mapdl = Mock()
    mock_mapdl.some_method.return_value = expected_value
    ...

Existing fixtures are in tests/conftest.py (especially the mapdl fixture).

Conditional skipping

Use requires() from conftest.py instead of pytest.mark.skipif:

from conftest import requires


@requires("local")
def test_local_feature(mapdl): ...


@requires("remote")
def test_remote_feature(mapdl): ...

Accepted strings: "local", "remote", "grpc", "console", "dpf", "linux", "nolinux", "windows", "nowindows", "xserver", "cicd", "nocicd", "gui", or any importable package name.

Key env vars

Variable Purpose
PYMAPDL_START_INSTANCE Set to False to connect to an existing instance instead of launching one
PYMAPDL_PORT gRPC server port (default 50052)
PYMAPDL_IP gRPC server IP (default 127.0.0.1)
ON_LOCAL Force local mode detection
ON_CI Marks run as CI; some tests skip

pytest config

Configured with --maxfail=2 in pyproject.toml. Override locally:

uv run pytest -p no:randomly --maxfail=100

CI-like testing via tox + Docker

Same tox envs as documented in the developer agent. For testers, typical workflow:

If running test locally against local Docker images:

export PYMAPDL_PORT=50052
export PYMAPDL_START_INSTANCE=True
uvx tox -e docker-run-mapdl
pytest -v
uvx tox -e docker-stop-mapdl # Stop MAPDL

If running test locally inside a container (mirroring CI):

uvx tox -e docker-test-local    # or docker-test-remote to mirror CI exactly

Each directory that needs env vars contains an example.env. Copy to .env — tox loads it automatically.

Read the full file on GitHub · 87 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 87 lines · 37 tokens per session scan A c3eb9c6413c8

Subscribe to this mod's changes

tester is an agent published in the GitHub repository ansys/pymapdl (513 stars, last pushed 3d ago), licensed MIT. It adds 37 tokens to every session and 598 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other agents, from other repositories

ring:qa

Senior QA Analyst for financial systems. Supports 6 testing modes — unit (default), fuzz, property, integration, chaos, goroutine-leak. Dispatched by orchestrator with mode parameter; loads mode-specific file from qa-modes/.

LerianStudio/ring · 52 tokens

pydantic-ai-validator

Testing and validation specialist for Pydantic AI agents. USE AUTOMATICALLY after agent implementation to create comprehensive tests, validate functionality, and ensure readiness. Uses TestModel and FunctionModel for thorough validation.

coleam00/context-engineering-intro · 46 tokens

func-verifier

RAT audit protocol (condensed; dev source: plugindocs/agent-lib/audit-output-protocol.md — plugin-internal, do NOT Read it at runtime).

babyworm/rtl-agent-team · 43 tokens

developer

Implement Idea and scoreidea in src/backlog.py, and verify them with tests/testbacklog.py. Use the formula impact 5 + strategicfit 3 - effort 2.

bonigarcia/context-engineering · 0 tokens

unit-test-writer

Use this agent when you need to write comprehensive unit tests for Go code, particularly for functions, methods, or components that require thorough testing coverage. Examples: Context: User has just written a new function and wants unit tests for it. user: 'I just wrote this function to validate email addresses, can…

stacklok/toolhive-registry-server · 228 tokens

testing-strategies-prompt

You are a testing specialist agent. Your mission: design and implement comprehensive testing strategies, ensure code quality through systematic testing, and guide test-driven development practices.

Rtur2003/Claude-Code-Promts-Skills · 0 tokens