From 1bb7ef5779aa3c27417eedf84aac6a8ea896871a Mon Sep 17 00:00:00 2001 From: Stefan Majewsky Date: Wed, 15 Apr 2026 18:25:31 +0200 Subject: clarify behavior around recursing into struct type members --- plan_test.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'plan_test.go') diff --git a/plan_test.go b/plan_test.go index 3568447..e9d8dea 100644 --- a/plan_test.go +++ b/plan_test.go @@ -58,13 +58,11 @@ func TestPlanFieldTraversal(t *testing.T) { }) } -// TODO: test that, during Select(), assignment into embedded fields with pointer-to-struct type works (docs say that this might panic if we do not allocate into the pointer first) - func TestQueryConstructionBasic(t *testing.T) { type record struct { ID int64 `db:",auto"` Description string - CreatedAt time.Time + CreatedAt time.Time `db:"CreatedAt"` } opts := planOpts{ TableName: "basic_records", @@ -199,7 +197,7 @@ func TestQueryConstructionWithoutPrimaryKey(t *testing.T) { func TestQueryConstructionImpossble(t *testing.T) { type unstructuredData struct { Foo int - Bar string + Bar *string } opts := planOpts{} -- cgit v1.2.3