datagsm-server: Agent for Claude Code

.claude/agents/kotlin-test-fixer.md

kotlin-test-fixer is an agent for Claude Code from themoment-team/datagsm-server. It costs 211 tokens per session (1,529 once invoked), scanned B, original, MIT.

A pull-request helper that examines commits and file changes, creates a title and description, chooses labels, and opens the pull request on GitHub. A pull request is a request to review and merge a set of changes into a code branch.

In plain words
What is it for?
It detects the base branch, summarizes the diff, reads the pull-request template and label guidance, generates title options and a body, selects labels, and creates the GitHub pull request.
Why use it?
It removes repetitive work when turning a completed branch into a review request. It also uses the project's templates and commit rules to shape the result.

Agent for Claude Code

Written for Claude Code: installed under .claude/. Also seen: model in frontmatter; mentions AGENTS.md.

This is themoment-team/datagsm-server's own configuration. It tells Claude Code how to work on datagsm-server itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything datagsm-server configures →

Reuse

Borrowing it

Nothing to install: this file belongs to themoment-team/datagsm-server. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/themoment-team/datagsm-server/master/.claude/agents/kotlin-test-fixer.md
Clone the repo
git clone --depth 1 https://github.com/themoment-team/datagsm-server

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for kotlin-test-fixer

README.md
[![agentmods](https://agentmods.dev/badge/agents/themoment-team/datagsm-server/kotlin-test-fixer/github.svg)](https://agentmods.dev/agents/themoment-team/datagsm-server/kotlin-test-fixer)
Your own site
<a href="https://agentmods.dev/agents/themoment-team/datagsm-server/kotlin-test-fixer"><img src="https://agentmods.dev/badge/agents/themoment-team/datagsm-server/kotlin-test-fixer/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for kotlin-test-fixer

Your own site · 80×15
<a href="https://agentmods.dev/agents/themoment-team/datagsm-server/kotlin-test-fixer"><img src="https://agentmods.dev/badge/agents/themoment-team/datagsm-server/kotlin-test-fixer.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 211 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,529 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00211 $0.01529
Opus 5.5 $0.00084 $0.00612
Sonnet 5.5 $0.00042 $0.00306
Haiku 4.5 $0.00021 $0.00153

Measured 19d ago against content hash 9eeeabaa54b8, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade B, and why

kotlin-test-fixer scanned grade B with 1 finding 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 19d 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.

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

find .claude/rules -name "*.md" 2>/dev/null
.claude/agents/kotlin-test-fixer.md · 152 lines

How it starts

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

You are a Kotlin/Kotest test repair agent. Your job is to run failing tests, diagnose root causes, apply targeted fixes to service or test code, and verify that all tests pass. You treat service code as the source of truth — but you will also fix genuine service bugs when they are the root cause of a failure.

Project Structure

  • Test framework: Kotest (DescribeSpec / BehaviorSpec) + MockK
  • Test files: src/test/kotlin/**/*Test.kt
  • Service files: src/main/kotlin/**/*ServiceImpl.kt
  • Test command: ./gradlew :<module>:test 2>&1

Step 1: Determine Target Module

First, discover available Gradle modules:

cat settings.gradle.kts 2>/dev/null || cat settings.gradle 2>/dev/null

If the user specifies a module name, run:

./gradlew :<module>:test 2>&1

If no module is specified, run all tests:

./gradlew test 2>&1

Parse the output. If all tests pass, report success and exit.

Step 2: Retry Loop (max 3 attempts)

Repeat until all tests pass OR attempt count reaches 3:

2a. Parse Failures

Extract from Gradle test output:

  • Failing test class name and method name
  • Exception type and message
  • Stack trace (especially the first non-framework frame)

2b. Locate Files

For each failing test class FooServiceTest:

  • Find the test file: Glob("**/*FooServiceTest.kt")
  • Find the corresponding service implementation: Glob("**/*FooServiceImpl.kt") or Glob("**/*FooService.kt")
  • Read both files completely

2c. Diagnose Failure Root Cause

Use the following decision table:

Failure Pattern Root Cause Fix Target
UnsatisfiedMockKStubbing / no answer for Service method signature changed Update test mock setup
shouldBe / shouldNotBe assertion mismatch (value differs) Service logic changed or has a bug Inspect service first, then decide
NullPointerException inside service implementation Service null-safety issue Fix service
shouldThrow<ExpectedException> but no exception thrown Service missing throw, or test scenario is wrong Inspect service logic to decide
Compilation error in test (unresolved reference, type mismatch) Service API changed (method renamed/removed/signature changed) Update test to match new API
ClassCastException or wrong type returned Service return type or DTO mapping changed Inspect service, fix accordingly

Read the full file on GitHub · 152 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. 19d ago Changed · +1 lines 9eeeabaa54b8
  2. 29d ago First seen · 151 lines · 211 tokens per session scan B e7d4279cc266

Subscribe to this mod's changes

kotlin-test-fixer is an agent published in the GitHub repository themoment-team/datagsm-server (29 stars, last pushed yesterday), licensed MIT. It adds 211 tokens to every session and 1,529 once invoked, about $0.0008 per session on Opus 5.5. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-08.

Related

kotlin-test-fixer compared with agents from other repositories

kotlin-test-fixer next to 6 agents from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
kotlin-test-fixerthemoment-team/datagsm-serverAgent29yesterdayMITB211Claude Code
playwright-test-generatormicrosoft/playwrightAgent99kyesterdayApache-2.0A151Claude Code
.NET-Notebook-Migration-Agentmicrosoft/ai-agents-for-beginnersAgent79k4d agoMITA33Claude Code
code-revieweranthropics/claude-cookbooksAgent54k2d agoMITA52Claude Code
AVM Owner Triagegithub/awesome-copilotAgent41kyesterdayMITA61Claude Code
Ultimate Transparent Thinking Beast Modegithub/awesome-copilotAgent41kyesterdayMITA11Claude Code
WinForms Expertgithub/awesome-copilotAgent41kyesterdayMITA19Claude Code