/**
 * @fileoverview Input validator compilation, testing, and execution utilities.
 * Provides functions to run validators on test inputs with testset support.
 */
import type { LocalValidator, LocalTestset } from '../types';
/**
 * Compiles the validator program.
 * Wrapper around compileCPP with consistent error handling.
 *
 * @param {LocalValidator} validator - Validator configuration
 * @returns {Promise<void>} Does not return anything on success
 *
 * @throws {Error} If compilation fails
 *
 * @example
 * await compileValidator({ name: 'val', source: 'validator/val.cpp' });
 */
export declare function compileValidator(validator: LocalValidator): Promise<void>;
/**
 * Validates a single test in a testset.
 *
 * @param {LocalValidator} validator - Validator configuration
 * @param {string} testsetName - Testset name
 * @param {number} testIndex - 1-based test index
 *
 * @throws {Error} If validator compilation fails
 * @throws {Error} If test is invalid
 *
 * @example
 * await validateSingleTest(validator, 'testsets', 5);
 */
export declare function validateSingleTest(validator: LocalValidator, testsetName: string, testIndex: number): Promise<void>;
/**
 * Validates all tests in a testset.
 *
 * @param {LocalValidator} validator - Validator configuration
 * @param {string} testsetName - Testset name
 *
 * @throws {Error} If validator compilation fails
 * @throws {Error} If any test is invalid
 *
 * @example
 * await validateTestset(validator, 'testsets');
 */
export declare function validateTestset(validator: LocalValidator, testsetName: string): Promise<void>;
/**
 * Validates tests in a specific group within a testset.
 *
 * @param {LocalValidator} validator - Validator configuration
 * @param {LocalTestset} testset - Testset configuration
 * @param {string} groupName - Group name
 *
 * @throws {Error} If validator compilation fails
 * @throws {Error} If any test in group is invalid
 *
 * @example
 * await validateGroup(validator, testset, 'samples');
 */
export declare function validateGroup(validator: LocalValidator, testset: LocalTestset, groupName: string): Promise<void>;
/**
 * Validates all testsets.
 *
 * @param {LocalValidator} validator - Validator configuration
 * @param {LocalTestset[]} testsets - All testsets
 *
 * @throws {Error} If validator compilation fails
 * @throws {Error} If any test is invalid
 *
 * @example
 * await validateAllTestsets(validator, testsets);
 */
export declare function validateAllTestsets(validator: LocalValidator, testsets: LocalTestset[]): Promise<void>;
/**
 * Ensures a validator is defined in the configuration.
 * Type assertion function that throws if validator is undefined.
 *
 * @param {LocalValidator | undefined} validator - Validator configuration to validate
 *
 * @throws {Error} If no validator is defined in configuration
 *
 * @example
 * const config = readConfigFile();
 * ensureValidatorExists(config.validator);
 * // Now TypeScript knows validator is defined
 */
export declare function ensureValidatorExists(validator: LocalValidator | undefined): asserts validator is LocalValidator;
/**
 * Tests the validator against its own test suite.
 * Compiles the validator, creates test files, runs all tests, and cleans up.
 * This is a cancellation point - fails fast on first error.
 *
 * @throws {Error} If validator tests fail
 * @throws {Error} If validator compilation fails
 * @throws {Error} If test file parsing fails
 *
 * @example
 * // From actions.ts testWhat and fullVerification
 * await testValidatorItself();
 */
export declare function testValidatorItself(): Promise<void>;
/**
 * Runs all validator self-tests and validates results.
 * Compiles the validator and runs it against all test cases.
 * Fails fast - throws on first test failure.
 *
 * @param {LocalValidator} validator - Validator configuration
 *
 * @throws {Error} If validator compilation fails
 * @throws {Error} If any test fails
 *
 * @example
 * const config = readConfigFile();
 * await runValidatorTests(config.validator);
 */
export declare function runValidatorTests(validator: LocalValidator): Promise<void>;
//# sourceMappingURL=validator.d.ts.map