create_test_suite_skill

This skill guides you to design a comprehensive Beluga AI Go test suite with mocks, performance tests, and OTEL validation.
  • Go

5

GitHub Stars

1

Bundled Files

2 months ago

Catalog Refreshed

4 months ago

First Indexed

Readme & install

Copy the install command, review bundled files from the catalogue, and read any extended description pulled from the listing source.

Installation

Preview and clipboard use veilstrat where the catalogue uses aiagentskills.

npx veilstrat add skill lookatitude/beluga-ai --skill create_test_suite

  • SKILL.md11.8 KB

Overview

This skill creates a comprehensive test suite for a Go package following Beluga AI testing standards. It provides templates, utilities, and a checklist to cover table-driven tests, concurrency, load, error scenarios, OTEL validation, registry checks, and benchmarks. The goal is high confidence, race-free runs, and target coverage thresholds.

How this skill works

The skill scaffolds test_utils.go with configurable mocks, a concurrent test runner, and load-test helpers. It generates advanced_test.go with table-driven cases, concurrency and load tests, error scenario validation, OTEL metrics checks, provider registry tests, and benchmarks. It also includes commands and a checklist for running tests with race detection, coverage, and benchmarks.

When to use it

  • Adding or hardening tests for a new or existing Go package
  • Ensuring concurrency safety and race-free behavior
  • Validating error handling, timeouts, and context cancellation
  • Measuring performance and P99 latency under load
  • Verifying OTEL metrics and multi-provider registry behavior

Best practices

  • Start by creating a Test Assessment that lists public API, providers, configs, errors, and edge cases
  • Use configurable mocks (errors, delays, response functions) to simulate real behaviors
  • Favor table-driven tests for wide coverage and readable scenarios
  • Run tests with -race and maintain CI steps for coverage and benchmarks
  • Skip long-running load tests in short mode and assert strict P99 latency and success rate targets

Example use cases

  • Create tests for a new Component that exposes NewComponent and Process methods
  • Simulate provider registration and validate unknown-provider error handling
  • Run concurrent access and race detection on critical methods using ConcurrentTestRunner
  • Execute load tests to assert success rate > 99% and P99 latency < 100ms
  • Validate OTEL metrics are recorded after operations and integrate metrics into CI

FAQ

Aim for 100% coverage on critical paths and at least 80% overall for the package.

How should load tests be handled in CI?

Run load tests selectively: skip in short mode and include them in a dedicated performance pipeline or nightly job.

When should I create registry tests?

Add registry tests when the package supports multiple providers or has a provider factory/registry mechanism.

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational