Skip to content

Commit

Permalink
Re-add existing test so that the fix is tested separately
Browse files Browse the repository at this point in the history
  • Loading branch information
voidcontext committed Feb 9, 2024
1 parent 6158054 commit 221d7b1
Showing 1 changed file with 10 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,16 @@ class TracedTransactorTest extends CatsEffectSuite {
}

database.test("Trace updates") { db =>
val create = sql"CREATE TABLE a (id INT, name VARCHAR)".update.run
val insert =
sql"INSERT INTO a VALUES (${2: Int}, ${"abc": String})".update.run
assertIO(
run((create >> insert).transact(db)).map(_.last),
SpanData("test-db:db.execute:INSERT INTO a VALUES (?, ?)", Map("span.type" -> "db"))
)
}

database.test("Trace updates withUniqueGeneratedKeys") { db =>
val create = sql"CREATE TABLE a (id INT, name VARCHAR)".update.run
val insert =
sql"INSERT INTO a VALUES (${2: Int}, ${"abc": String})".update.withUniqueGeneratedKeys[String]("name")
Expand Down

0 comments on commit 221d7b1

Please sign in to comment.