Skip to content

Commit

Permalink
Fix linter errors
Browse files Browse the repository at this point in the history
  • Loading branch information
nineinchnick authored and wendigo committed May 3, 2024
1 parent 18d7885 commit 47eee6e
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
3 changes: 3 additions & 0 deletions trino/integration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -588,6 +588,9 @@ func TestIntegrationQueryNextAfterClose(t *testing.T) {

ctx := context.Background()
conn, err := (&Driver{}).Open(*integrationServerFlag)
if err != nil {
t.Fatalf("Failed to open connection: %v", err)
}
defer conn.Close()

stmt, err := conn.(driver.ConnPrepareContext).PrepareContext(ctx, "SELECT 1")
Expand Down
1 change: 1 addition & 0 deletions trino/integration_tls_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.

//go:build go1.9
// +build go1.9

package trino
Expand Down
5 changes: 3 additions & 2 deletions trino/trino_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -358,6 +358,7 @@ func TestQueryProgressWithCallbackPeriod(t *testing.T) {
statusMap: statusMap,
}
progressUpdaterPeriod, err := time.ParseDuration("1ms")
require.NoError(t, err)

rows, err := db.Query("SELECT 2",
sql.Named("X-Trino-Progress-Callback", progressUpdater),
Expand Down Expand Up @@ -1753,10 +1754,10 @@ func TestExec(t *testing.T) {
assert.NoError(t, db.Close())
})

result, err := db.Exec("CREATE TABLE memory.default.test (id INTEGER, name VARCHAR, optional VARCHAR)")
_, err = db.Exec("CREATE TABLE memory.default.test (id INTEGER, name VARCHAR, optional VARCHAR)")
require.NoError(t, err, "Failed executing CREATE TABLE query")

result, err = db.Exec("INSERT INTO memory.default.test (id, name, optional) VALUES (?, ?, ?), (?, ?, ?), (?, ?, ?)",
result, err := db.Exec("INSERT INTO memory.default.test (id, name, optional) VALUES (?, ?, ?), (?, ?, ?), (?, ?, ?)",
123, "abc", nil,
456, "def", "present",
789, "ghi", nil)
Expand Down

0 comments on commit 47eee6e

Please sign in to comment.