Testing & Performance

Semantic ID Generator includes comprehensive test suites and regularly benchmarked performance targets. Use this page to navigate everything related to quality assurance.

Running the test suite

npm test

TypeScript-specific checks

npm run test:typescript

These commands cover unit tests (mocha), TypeScript compilation, and definition validation.

Test coverage overview

File Focus
01-semantic-id-generator.test.js Core ID generation
02-check-configuration.test.js Configuration validation
03-check-performances.test.js Performance smoke tests
04-unicode-string-generation.test.js Unicode strategy correctness
05-base64-strategy.test.js Base64 strategy coverage
06-passphrase-strategy.test.js Passphrase caching + entropy
07-random-strategy-coverage.test.js Strategy randomness guarantees
08-domain-presets-and-schema.test.js Preset hydration + schema exports
typescript-compilation.test.ts TS compilation for consumers
typescript-definitions.test.ts Type definitions accuracy

Performance benchmarks

General generation

Unicode strategy

Strategy throughput

Security guarantees

Dependency snapshot

Type Packages
Runtime uuid@^11.1.0
Dev chai, mocha, ts-node, typescript, @types/*

Refer to package.json for exact versions.

Performance tips