testmodels

package
v0.4.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 27, 2026 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Account

type Account struct {
	gorm.Model
	Owner string `gorm:"size:120;not null"`
}

Account is a second, unrelated GORM model used by makemigrations integration tests to exercise a migration that adds one new model without repeating a model an earlier migration already covers.

type Gadget added in v0.4.0

type Gadget struct {
	gorm.Model
	Name string `gorm:"not null;default:'changed'"`
}

Gadget has a NOT NULL column with a database default, used by the lint and gate parity tests: changing the default makes Atlas rebuild a SQLite table with an IFNULL copy.

type Item added in v0.4.0

type Item struct {
	gorm.Model
	Name  string `gorm:"size:120;not null"`
	Price int64  `gorm:"not null"`
}

Item is Product renamed (table items), used by the table-rename tests.

type Product

type Product struct {
	gorm.Model
	Name  string `gorm:"size:120;not null"`
	Price int64  `gorm:"not null"`
}

Product is a GORM model used by makemigrations integration tests.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL