Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for keywords (0.18 sec)

  1. tests/non_std_test.go

    package tests_test
    
    import (
    	"testing"
    	"time"
    )
    
    type Animal struct {
    	Counter    uint64 `gorm:"primary_key:yes"`
    	Name       string `gorm:"DEFAULT:'galeone'"`
    	From       string // test reserved sql keyword as field name
    	Age        *time.Time
    	unexported string // unexported value
    	CreatedAt  time.Time
    	UpdatedAt  time.Time
    }
    
    func TestNonStdPrimaryKeyAndDefaultValues(t *testing.T) {
    	DB.Migrator().DropTable(&Animal{})
    Go
    - Registered: Sun Apr 28 09:35:09 GMT 2024
    - Last Modified: Thu Jan 06 07:02:53 GMT 2022
    - 1.9K bytes
    - Viewed (0)
Back to top