Skip to main content
Testereiro - Test Engine Toolkit for Go
Go Docs GitHub Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Back to homepage

v0.7.0

Summary

Engine.Seed names the table it inserts into from the type name, and that rule now pluralizes the way table names are actually written, with an explicit name for the tables it cannot derive.

Breaking Changes

The derived table name changed for two shapes of type name:

  • A name ending in x is no longer suffixed: JobOutbox seeds job_outbox, not job_outboxs.
  • A consonant before the final y takes ies: JobCategory seeds job_categories, not job_categorys. A vowel before it still takes s, so ApiKey keeps seeding api_keys.

Every other name still takes a plain s.

Core Library (puppetest)

  • A seeded type with a TableName() string method inserts into the table it returns, so a table outside the plural rule (tenant_usage_monthly) can be seeded. A generated row gains the method through a defined type over it.