tm-tests

Generate security test cases from threat models in Markdown, Jest, Pytest, or Playwright formats.

8|1|Updated Jan 20, 2026
One-click install
npx skills add https://github.com/josemlopez/threat-modeling-toolkit --skill tm-tests
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: tm-tests
Source: https://github.com/josemlopez/threat-modeling-toolkit/tree/main/skills/tm-tests
Command: npx skills add https://github.com/josemlopez/threat-modeling-toolkit --skill tm-tests

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps security teams automatically generate test cases from threat models, ensuring comprehensive coverage of threats and controls without manual scripting.

Core Features & Use Cases

  • Attack scenario tests: Generate realistic scenarios to verify detection and response.
  • Control verification tests: Confirm security controls are active and correctly configured.
  • Regression test suites: Build ongoing test suites to prevent security regressions across releases.
  • Threat-to-test mapping: Link tests to specific threats and mitigations for traceability.

Quick Start

Use the tm-tests skill to generate security tests from the current threat model and export them in your preferred format.

Frequently Asked Questions about tm-tests

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate security test cases from a threat model?

To generate security test cases from a threat model, you provide threat model data including assets, threats, and controls to automatically create attack scenarios and control verifications in Markdown, Jest, Pytest, or Playwright formats.

What is threat-to-test mapping and how does it validate security controls?

Threat-to-test mapping links generated tests to specific threats and mitigations to validate security controls. This ensures comprehensive threat coverage and traceability, confirming that controls are active and correctly configured.

Can I generate security regression suites in Jest or Pytest from threat analysis artifacts?

Yes, you can generate security regression suites in Jest, Pytest, or Playwright from threat analysis artifacts. These suites prevent security regressions across releases by validating mitigations and controls.

What threat model data is required to generate attack scenario tests?

Generating attack scenario tests requires threat model data containing defined assets, threats, and controls. This data is processed to create realistic scenarios that verify threat detection and response capabilities.

Does the tool work with Playwright for control verification tests?

Yes, the tool supports Playwright for control verification tests. It outputs tests in Playwright format to confirm that security controls are active and correctly configured within your software projects.