Skip to content

Commit

Permalink
Additional test for $nr parameters
Browse files Browse the repository at this point in the history
  • Loading branch information
nene committed Feb 13, 2024
1 parent 2582aba commit 54faa15
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions test/options/paramTypes.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,12 @@ describe("sqlParamTypes option", () => {
});
});

it(`indexed parameters: $nr`, async () => {
await test(`SELECT * FROM tbl WHERE x = $1 AND y = $2`, {
sqlParamTypes: ["$nr"],
});
});

it(`named parameters: :name`, async () => {
await test(`SELECT * FROM tbl WHERE x = :foo AND y = :bar`, {
sqlParamTypes: [":name"],
Expand Down

0 comments on commit 54faa15

Please sign in to comment.