Avoid unnecessary double wrapping of SELECT statement when used as single function parameter.

This commit is contained in:
go-jet 2021-10-21 13:35:37 +02:00
parent 22b2901336
commit d197956271
16 changed files with 97 additions and 77 deletions

View file

@ -4,10 +4,9 @@ import (
"context"
"database/sql"
"fmt"
"github.com/go-jet/jet/v2/tests/internal/utils/repo"
"math/rand"
"os"
"os/exec"
"strings"
"testing"
"time"
@ -53,13 +52,7 @@ func TestMain(m *testing.M) {
}
func setTestRoot() {
cmd := exec.Command("git", "rev-parse", "--show-toplevel")
byteArr, err := cmd.Output()
if err != nil {
panic(err)
}
testRoot = strings.TrimSpace(string(byteArr)) + "/tests/"
testRoot = repo.GetTestsDirPath()
}
var loggedSQL string