Testing Made Simple

Write less test code. Get better coverage. Supernal Interface automatically generates type-safe tests from your tool definitions.

1. Auto-Generated Test Cases

Every @Tool decorator automatically generates type-safe test scenarios from your tool definitions

Zero test writing overhead
Type-safe validation
Always in sync with code
@Tool({ description: 'Reset counter to zero' })
function resetCounter() {
  setCount(0);
}

// Auto-generates:
// ✓ Test: "should reset counter to zero"
// ✓ Validates: function exists
// ✓ Validates: executes without error
// ✓ Validates: state changes correctly

2. Gherkin Story Testing

Write human-readable feature files that execute as automated tests

Business-readable tests
Cacheable scenarios
State-aware execution
Feature: Counter Component
  Scenario: Increment counter
    Given the counter is at 0
    When I increment the counter
    Then the counter should be at 1
    And the display should show "1"

3. Component State Validation

Automatically validate component state before and after tool execution

Catch state bugs early
Clear error messages
Contract-based validation
@Tool({
  description: 'Set counter',
  preConditions: ['counter exists'],
  postConditions: ['counter value updated']
})
function setCounter(value: number) {
  setCount(value);
}

4. Test Coverage Reports

Track which tools are tested and identify gaps in your test suite

Visual coverage metrics
Identify untested tools
CI/CD integration
npm run test:coverage

Tool Coverage Report:
✓ resetCounter    100%  (3/3 scenarios)
✓ increment       100%  (2/2 scenarios)
⚠ decrement       66%   (2/3 scenarios)
✗ complexAction   0%    (0/1 scenarios)

How It Works

1️⃣

Decorate Your Functions

Add @Tool decorators to any function you want to make AI-controllable

2️⃣

Run Test Generation

Our CLI scans your code and generates type-safe test scenarios automatically

3️⃣

Execute & Monitor

Run tests in CI/CD, get coverage reports, and catch regressions early

Ready to Automate Your Testing?

Get started with Supernal Interface and spend less time writing tests, more time shipping features.

DEBUG &&