mirror of
https://github.com/ncruces/go-sqlite3.git
synced 2026-01-12 05:59:14 +00:00
Build using wasi-sdk.
This commit is contained in:
@@ -49,14 +49,18 @@ func TestConn_new(t *testing.T) {
|
||||
}
|
||||
defer m.close()
|
||||
|
||||
testOOM := func(size uint64) {
|
||||
t.Run("MaxUint32", func(t *testing.T) {
|
||||
defer func() { _ = recover() }()
|
||||
m.new(size)
|
||||
m.new(math.MaxUint32)
|
||||
t.Error("want panic")
|
||||
}
|
||||
})
|
||||
|
||||
testOOM(math.MaxUint32)
|
||||
testOOM(_MAX_ALLOCATION_SIZE)
|
||||
t.Run("_MAX_ALLOCATION_SIZE", func(t *testing.T) {
|
||||
defer func() { _ = recover() }()
|
||||
m.new(_MAX_ALLOCATION_SIZE)
|
||||
m.new(_MAX_ALLOCATION_SIZE)
|
||||
t.Error("want panic")
|
||||
})
|
||||
}
|
||||
|
||||
func TestConn_newArena(t *testing.T) {
|
||||
|
||||
Reference in New Issue
Block a user