Files
zeekay 3fd1aee1fc Take the current zip, and the rest of the estate with it
zip v1.27.0 -> v1.34.0. Seven minors, and the one that matters is v1.32.0: a
refusal is an RFC 9457 problem document now, so `error` reads `detail`. Nothing
here reads that field — 11 packages green, vet clean.

It also brings zip.Undeclared (v1.33.1), which is how an address serves without
entering the contract. A retirement needs exactly that: a retired address
answers 410 for every method, so publishing it would be one operation per method
per address.

orm, sqlite, money, ha, iamsdk and csqlite move to their latest.

authz STAYS at v1.10.14, alone among these. v1.10.20 dropped persist/string-adapter
and model, which authz/authz.go imports, and this is the last consumer of them:

  v1.10.14  HAS persist/string-adapter
  v1.10.20  missing
  v1.10.35  missing

Moving it is a migration off that adapter, not a pin bump.
2026-08-22 07:44:46 -07:00

50 lines
1.6 KiB
Go

// Copyright 2023 Hanzo Industries Inc. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package object
import (
"database/sql"
"path/filepath"
"testing"
_ "github.com/hanzoai/sqlite"
)
// TestDSNAppliesTheDurabilityProfile opens a real file and asks the database
// what it got, rather than asserting on the DSN string. The string is exactly
// what differs between the two backends — each silently ignores the other's
// spelling — so a string comparison would pass on the build that ignores it.
func TestDSNAppliesTheDurabilityProfile(t *testing.T) {
db, err := sql.Open("sqlite", dsn(filepath.Join(t.TempDir(), "t.db")))
if err != nil {
t.Fatalf("open: %v", err)
}
defer func() { _ = db.Close() }()
for _, c := range []struct{ pragma, want string }{
{"journal_mode", "wal"},
{"foreign_keys", "1"},
{"busy_timeout", "10000"},
} {
var got string
if err := db.QueryRow("PRAGMA " + c.pragma).Scan(&got); err != nil {
t.Fatalf("PRAGMA %s: %v", c.pragma, err)
}
if got != c.want {
t.Errorf("%s = %q, want %q — the DSN asked for it and the backend did not take it", c.pragma, got, c.want)
}
}
}