(b *testing.B)
| 316 | } |
| 317 | |
| 318 | func BenchmarkExecContext(b *testing.B) { |
| 319 | db := initDB(b, false, |
| 320 | "DROP TABLE IF EXISTS foo", |
| 321 | "CREATE TABLE foo (id INT PRIMARY KEY, val CHAR(50))", |
| 322 | `INSERT INTO foo VALUES (1, "one")`, |
| 323 | `INSERT INTO foo VALUES (2, "two")`, |
| 324 | ) |
| 325 | defer db.Close() |
| 326 | for _, p := range []int{1, 2, 3, 4} { |
| 327 | b.Run(fmt.Sprintf("%d", p), func(b *testing.B) { |
| 328 | benchmarkExecContext(b, db, p) |
| 329 | }) |
| 330 | } |
| 331 | } |
| 332 | |
| 333 | // BenchmarkQueryRawBytes benchmarks fetching 100 blobs using sql.RawBytes. |
| 334 | // "size=" means size of each blobs. |
nothing calls this directly
no test coverage detected