Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 1 - 1 of 1 for TestChainableAPI (0.09 seconds)

  1. tests/chainable_api_test.go

    		Clauses:  map[string]clause.Clause{},
    		Preloads: map[string][]interface{}{},
    		Context:  context.Background(),
    		Vars:     make([]interface{}, 0),
    	}
    	db.Statement = stmt
    	return db
    }
    
    func TestChainableAPI(t *testing.T) {
    	db := newTestDB()
    
    	// Model
    	m := &struct{ ID int }{}
    	tx := db.Model(m)
    	if tx.Statement.Model != m {
    		t.Fatalf("Model not set, got %v", tx.Statement.Model)
    	}
    
    	// Table
    Created: Sun Apr 05 09:35:12 GMT 2026
    - Last Modified: Sat Jan 31 08:39:40 GMT 2026
    - 3.9K bytes
    - Click Count (0)
Back to Top