Модуль переименован для публикации
Некоторые проверки провалились
test / test (1.16.x) (push) Has been cancelled
test / test (1.17.x) (push) Has been cancelled
test / test (oldstable) (push) Has been cancelled
test / test (stable) (push) Has been cancelled
Некоторые проверки провалились
test / test (1.16.x) (push) Has been cancelled
test / test (1.17.x) (push) Has been cancelled
test / test (oldstable) (push) Has been cancelled
test / test (stable) (push) Has been cancelled
Этот коммит содержится в:
родитель
eff1e7e3c6
коммит
ffcc5b10ae
64 изменённых файлов: 137 добавлений и 137 удалений
|
@ -5,7 +5,7 @@ import (
|
||||||
"encoding/json"
|
"encoding/json"
|
||||||
"net/http"
|
"net/http"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
)
|
)
|
||||||
|
|
||||||
func getVersion(w http.ResponseWriter, r *http.Request) {
|
func getVersion(w http.ResponseWriter, r *http.Request) {
|
||||||
|
|
|
@ -9,7 +9,7 @@ import (
|
||||||
"reflect"
|
"reflect"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
)
|
)
|
||||||
|
|
||||||
type apiFeature struct {
|
type apiFeature struct {
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"os"
|
"os"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
"github.com/spf13/pflag"
|
"github.com/spf13/pflag"
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
)
|
)
|
||||||
|
|
|
@ -11,8 +11,8 @@ import (
|
||||||
"os"
|
"os"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
)
|
)
|
||||||
|
|
||||||
var opts = godog.Options{
|
var opts = godog.Options{
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
"io"
|
"io"
|
||||||
"math"
|
"math"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
|
@ -6,8 +6,8 @@ import (
|
||||||
"os"
|
"os"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
flag "github.com/spf13/pflag"
|
flag "github.com/spf13/pflag"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -11,7 +11,7 @@ import (
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
txdb "github.com/DATA-DOG/go-txdb"
|
txdb "github.com/DATA-DOG/go-txdb"
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
)
|
)
|
||||||
|
|
||||||
func init() {
|
func init() {
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
module github.com/cucumber/godog/_examples
|
module git.golang1.ru/softonik/godog/_examples
|
||||||
|
|
||||||
go 1.16
|
go 1.16
|
||||||
|
|
||||||
replace github.com/cucumber/godog => ../
|
replace git.golang1.ru/softonik/godog => ../
|
||||||
|
|
||||||
require (
|
require (
|
||||||
github.com/DATA-DOG/go-txdb v0.1.6
|
github.com/DATA-DOG/go-txdb v0.1.6
|
||||||
github.com/cucumber/godog v0.15.0
|
git.golang1.ru/softonik/godog v0.15.0
|
||||||
github.com/go-sql-driver/mysql v1.7.1
|
github.com/go-sql-driver/mysql v1.7.1
|
||||||
github.com/spf13/pflag v1.0.6
|
github.com/spf13/pflag v1.0.6
|
||||||
github.com/stretchr/testify v1.8.2
|
github.com/stretchr/testify v1.8.2
|
||||||
|
|
|
@ -15,12 +15,12 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"flag"
|
"flag"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/cucumber/godog/_examples/godogs"
|
"git.golang1.ru/softonik/godog/_examples/godogs"
|
||||||
"os"
|
"os"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
)
|
)
|
||||||
|
|
||||||
var opts = godog.Options{
|
var opts = godog.Options{
|
||||||
|
|
|
@ -2,6 +2,6 @@ module incorrect-project-structure
|
||||||
|
|
||||||
go 1.13
|
go 1.13
|
||||||
|
|
||||||
require github.com/cucumber/godog v0.15.0
|
require git.golang1.ru/softonik/godog v0.15.0
|
||||||
|
|
||||||
replace github.com/cucumber/godog => ../../
|
replace git.golang1.ru/softonik/godog => ../../
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import "github.com/cucumber/godog"
|
import "git.golang1.ru/softonik/godog"
|
||||||
|
|
||||||
func InitializeScenario(ctx *godog.ScenarioContext) {
|
func InitializeScenario(ctx *godog.ScenarioContext) {
|
||||||
|
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"go/build"
|
"go/build"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
|
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
"github.com/cucumber/godog/internal/builder"
|
"git.golang1.ru/softonik/godog/internal/builder"
|
||||||
|
|
||||||
"github.com/spf13/cobra"
|
"github.com/spf13/cobra"
|
||||||
)
|
)
|
||||||
|
@ -40,7 +40,7 @@ The test runner can be executed with the same flags as when using godog run.`,
|
||||||
|
|
||||||
func buildCmdRunFunc(cmd *cobra.Command, args []string) error {
|
func buildCmdRunFunc(cmd *cobra.Command, args []string) error {
|
||||||
fmt.Println(colors.Yellow("Use of godog CLI is deprecated, please use *testing.T instead."))
|
fmt.Println(colors.Yellow("Use of godog CLI is deprecated, please use *testing.T instead."))
|
||||||
fmt.Println(colors.Yellow("See https://github.com/cucumber/godog/discussions/478 for details."))
|
fmt.Println(colors.Yellow("See https://git.golang1.ru/softonik/godog/discussions/478 for details."))
|
||||||
|
|
||||||
bin, err := filepath.Abs(buildOutput)
|
bin, err := filepath.Abs(buildOutput)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"github.com/spf13/cobra"
|
"github.com/spf13/cobra"
|
||||||
"github.com/spf13/pflag"
|
"github.com/spf13/pflag"
|
||||||
|
|
||||||
"github.com/cucumber/godog/internal/flags"
|
"git.golang1.ru/softonik/godog/internal/flags"
|
||||||
)
|
)
|
||||||
|
|
||||||
var version bool
|
var version bool
|
||||||
|
|
|
@ -9,9 +9,9 @@ import (
|
||||||
|
|
||||||
"github.com/spf13/cobra"
|
"github.com/spf13/cobra"
|
||||||
|
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
"github.com/cucumber/godog/internal/builder"
|
"git.golang1.ru/softonik/godog/internal/builder"
|
||||||
"github.com/cucumber/godog/internal/flags"
|
"git.golang1.ru/softonik/godog/internal/flags"
|
||||||
)
|
)
|
||||||
|
|
||||||
var opts flags.Options
|
var opts flags.Options
|
||||||
|
@ -44,7 +44,7 @@ buildable go source.`,
|
||||||
|
|
||||||
func runCmdRunFunc(cmd *cobra.Command, args []string) error {
|
func runCmdRunFunc(cmd *cobra.Command, args []string) error {
|
||||||
fmt.Println(colors.Yellow("Use of godog CLI is deprecated, please use *testing.T instead."))
|
fmt.Println(colors.Yellow("Use of godog CLI is deprecated, please use *testing.T instead."))
|
||||||
fmt.Println(colors.Yellow("See https://github.com/cucumber/godog/discussions/478 for details."))
|
fmt.Println(colors.Yellow("See https://git.golang1.ru/softonik/godog/discussions/478 for details."))
|
||||||
|
|
||||||
osArgs := os.Args[1:]
|
osArgs := os.Args[1:]
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@ import (
|
||||||
|
|
||||||
"github.com/spf13/cobra"
|
"github.com/spf13/cobra"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
)
|
)
|
||||||
|
|
||||||
// CreateVersionCmd creates the version subcommand.
|
// CreateVersionCmd creates the version subcommand.
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"os"
|
"os"
|
||||||
|
|
||||||
"github.com/cucumber/godog/cmd/godog/internal"
|
"git.golang1.ru/softonik/godog/cmd/godog/internal"
|
||||||
)
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
|
|
|
@ -3,7 +3,7 @@ package godog_test
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
)
|
)
|
||||||
|
|
||||||
func ExampleTestSuite_Run_subtests() {
|
func ExampleTestSuite_Run_subtests() {
|
||||||
|
|
4
flags.go
4
flags.go
|
@ -8,8 +8,8 @@ import (
|
||||||
"strconv"
|
"strconv"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
"github.com/cucumber/godog/internal/utils"
|
"git.golang1.ru/softonik/godog/internal/utils"
|
||||||
)
|
)
|
||||||
|
|
||||||
// repeats a space n times
|
// repeats a space n times
|
||||||
|
|
|
@ -7,8 +7,8 @@ import (
|
||||||
"strings"
|
"strings"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
"github.com/cucumber/godog/internal/formatters"
|
"git.golang1.ru/softonik/godog/internal/formatters"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestFlagsShouldRandomizeAndGenerateSeed(t *testing.T) {
|
func TestFlagsShouldRandomizeAndGenerateSeed(t *testing.T) {
|
||||||
|
|
|
@ -8,7 +8,7 @@ import (
|
||||||
|
|
||||||
"github.com/spf13/pflag"
|
"github.com/spf13/pflag"
|
||||||
|
|
||||||
"github.com/cucumber/godog/internal/flags"
|
"git.golang1.ru/softonik/godog/internal/flags"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Choose randomly assigns a convenient pseudo-random seed value.
|
// Choose randomly assigns a convenient pseudo-random seed value.
|
||||||
|
|
|
@ -3,7 +3,7 @@ package godog
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/cucumber/godog/internal/flags"
|
"git.golang1.ru/softonik/godog/internal/flags"
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
10
fmt.go
10
fmt.go
|
@ -6,11 +6,11 @@ import (
|
||||||
"strings"
|
"strings"
|
||||||
"unicode/utf8"
|
"unicode/utf8"
|
||||||
|
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
"github.com/cucumber/godog/formatters"
|
"git.golang1.ru/softonik/godog/formatters"
|
||||||
internal_fmt "github.com/cucumber/godog/internal/formatters"
|
internal_fmt "git.golang1.ru/softonik/godog/internal/formatters"
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
"github.com/cucumber/godog/internal/storage"
|
"git.golang1.ru/softonik/godog/internal/storage"
|
||||||
)
|
)
|
||||||
|
|
||||||
// FindFmt searches available formatters registered
|
// FindFmt searches available formatters registered
|
||||||
|
|
|
@ -7,7 +7,7 @@ import (
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
)
|
)
|
||||||
|
|
||||||
func Test_FindFmt(t *testing.T) {
|
func Test_FindFmt(t *testing.T) {
|
||||||
|
|
|
@ -7,7 +7,7 @@ import (
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
)
|
)
|
||||||
|
|
||||||
func Test_FindFmt(t *testing.T) {
|
func Test_FindFmt(t *testing.T) {
|
||||||
|
|
2
go.mod
2
go.mod
|
@ -1,4 +1,4 @@
|
||||||
module github.com/cucumber/godog
|
module git.golang1.ru/softonik/godog
|
||||||
|
|
||||||
go 1.16
|
go 1.16
|
||||||
|
|
||||||
|
|
|
@ -9,7 +9,7 @@ import (
|
||||||
var astContextSrc = `package main
|
var astContextSrc = `package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
)
|
)
|
||||||
|
|
||||||
func MyContext(s *godog.Suite) {
|
func MyContext(s *godog.Suite) {
|
||||||
|
@ -18,7 +18,7 @@ func MyContext(s *godog.Suite) {
|
||||||
var astTwoContextSrc = `package lib
|
var astTwoContextSrc = `package lib
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
)
|
)
|
||||||
|
|
||||||
func ApiContext(s *godog.Suite) {
|
func ApiContext(s *godog.Suite) {
|
||||||
|
|
|
@ -23,13 +23,13 @@ var (
|
||||||
compiler = filepath.Join(tooldir, "compile")
|
compiler = filepath.Join(tooldir, "compile")
|
||||||
linker = filepath.Join(tooldir, "link")
|
linker = filepath.Join(tooldir, "link")
|
||||||
gopaths = filepath.SplitList(build.Default.GOPATH)
|
gopaths = filepath.SplitList(build.Default.GOPATH)
|
||||||
godogImportPath = "github.com/cucumber/godog"
|
godogImportPath = "git.golang1.ru/softonik/godog"
|
||||||
|
|
||||||
// godep
|
// godep
|
||||||
runnerTemplate = template.Must(template.New("testmain").Parse(`package main
|
runnerTemplate = template.Must(template.New("testmain").Parse(`package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
{{if or .TestSuiteContexts .ScenarioContexts}}_test "{{.ImportPath}}"{{end}}
|
{{if or .TestSuiteContexts .ScenarioContexts}}_test "{{.ImportPath}}"{{end}}
|
||||||
{{if or .XTestSuiteContexts .XScenarioContexts}}_xtest "{{.ImportPath}}_test"{{end}}
|
{{if or .XTestSuiteContexts .XScenarioContexts}}_xtest "{{.ImportPath}}_test"{{end}}
|
||||||
{{if or .XTestSuiteContexts .XScenarioContexts}}"testing/internal/testdeps"{{end}}
|
{{if or .XTestSuiteContexts .XScenarioContexts}}"testing/internal/testdeps"{{end}}
|
||||||
|
@ -70,7 +70,7 @@ func main() {
|
||||||
// temp file for import
|
// temp file for import
|
||||||
tempFileTemplate = template.Must(template.New("temp").Parse(`package {{.Name}}
|
tempFileTemplate = template.Must(template.New("temp").Parse(`package {{.Name}}
|
||||||
|
|
||||||
import "github.com/cucumber/godog"
|
import "git.golang1.ru/softonik/godog"
|
||||||
|
|
||||||
var _ = godog.Version
|
var _ = godog.Version
|
||||||
`))
|
`))
|
||||||
|
|
|
@ -12,8 +12,8 @@ import (
|
||||||
|
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
"github.com/cucumber/godog/internal/builder"
|
"git.golang1.ru/softonik/godog/internal/builder"
|
||||||
)
|
)
|
||||||
|
|
||||||
func InitializeScenario(ctx *godog.ScenarioContext) {}
|
func InitializeScenario(ctx *godog.ScenarioContext) {}
|
||||||
|
@ -51,7 +51,7 @@ var builderTestFile = `package godogs
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
)
|
)
|
||||||
|
|
||||||
func thereAreGodogs(available int) error {
|
func thereAreGodogs(available int) error {
|
||||||
|
@ -91,7 +91,7 @@ var builderXTestFile = `package godogs_test
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
|
|
||||||
"godogs"
|
"godogs"
|
||||||
)
|
)
|
||||||
|
@ -138,7 +138,7 @@ func main() {
|
||||||
|
|
||||||
var emptyBuilderTestFile = `package godogs
|
var emptyBuilderTestFile = `package godogs
|
||||||
|
|
||||||
import "github.com/cucumber/godog"
|
import "git.golang1.ru/softonik/godog"
|
||||||
|
|
||||||
func InitializeScenario(ctx *godog.ScenarioContext) {}
|
func InitializeScenario(ctx *godog.ScenarioContext) {}
|
||||||
`
|
`
|
||||||
|
|
|
@ -6,7 +6,7 @@ import (
|
||||||
"github.com/spf13/pflag"
|
"github.com/spf13/pflag"
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
|
|
||||||
"github.com/cucumber/godog/internal/flags"
|
"git.golang1.ru/softonik/godog/internal/flags"
|
||||||
)
|
)
|
||||||
|
|
||||||
func Test_BindFlagsShouldRespectFlagDefaults(t *testing.T) {
|
func Test_BindFlagsShouldRespectFlagDefaults(t *testing.T) {
|
||||||
|
|
|
@ -11,9 +11,9 @@ import (
|
||||||
|
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
|
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
"github.com/cucumber/godog/internal/utils"
|
"git.golang1.ru/softonik/godog/internal/utils"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
|
|
|
@ -12,11 +12,11 @@ import (
|
||||||
|
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
|
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
"github.com/cucumber/godog/formatters"
|
"git.golang1.ru/softonik/godog/formatters"
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
"github.com/cucumber/godog/internal/storage"
|
"git.golang1.ru/softonik/godog/internal/storage"
|
||||||
"github.com/cucumber/godog/internal/utils"
|
"git.golang1.ru/softonik/godog/internal/utils"
|
||||||
)
|
)
|
||||||
|
|
||||||
// BaseFormatterFunc implements the FormatterFunc for the base formatter.
|
// BaseFormatterFunc implements the FormatterFunc for the base formatter.
|
||||||
|
|
|
@ -7,8 +7,8 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
"github.com/cucumber/godog/internal/flags"
|
"git.golang1.ru/softonik/godog/internal/flags"
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -7,7 +7,7 @@ import (
|
||||||
"strings"
|
"strings"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
)
|
)
|
||||||
|
|
||||||
type csiState int
|
type csiState int
|
||||||
|
|
|
@ -19,8 +19,8 @@ import (
|
||||||
"sort"
|
"sort"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/cucumber/godog/formatters"
|
"git.golang1.ru/softonik/godog/formatters"
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"io"
|
"io"
|
||||||
|
|
||||||
"github.com/cucumber/godog/formatters"
|
"git.golang1.ru/softonik/godog/formatters"
|
||||||
"github.com/cucumber/godog/internal/utils"
|
"git.golang1.ru/softonik/godog/internal/utils"
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@ package formatters
|
||||||
import (
|
import (
|
||||||
"sync"
|
"sync"
|
||||||
|
|
||||||
"github.com/cucumber/godog/formatters"
|
"git.golang1.ru/softonik/godog/formatters"
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -9,8 +9,8 @@ import (
|
||||||
"strconv"
|
"strconv"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/cucumber/godog/formatters"
|
"git.golang1.ru/softonik/godog/formatters"
|
||||||
"github.com/cucumber/godog/internal/utils"
|
"git.golang1.ru/softonik/godog/internal/utils"
|
||||||
)
|
)
|
||||||
|
|
||||||
func init() {
|
func init() {
|
||||||
|
|
|
@ -3,8 +3,8 @@ package formatters
|
||||||
import (
|
import (
|
||||||
"io"
|
"io"
|
||||||
|
|
||||||
"github.com/cucumber/godog/formatters"
|
"git.golang1.ru/softonik/godog/formatters"
|
||||||
"github.com/cucumber/godog/internal/storage"
|
"git.golang1.ru/softonik/godog/internal/storage"
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"errors"
|
"errors"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/cucumber/godog/formatters"
|
"git.golang1.ru/softonik/godog/formatters"
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
)
|
)
|
||||||
|
|
|
@ -14,7 +14,7 @@ import (
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
)
|
)
|
||||||
|
|
||||||
const fmtOutputTestsFeatureDir = "formatter-tests/features"
|
const fmtOutputTestsFeatureDir = "formatter-tests/features"
|
||||||
|
@ -24,7 +24,7 @@ var tT *testing.T
|
||||||
func Test_FmtOutput(t *testing.T) {
|
func Test_FmtOutput(t *testing.T) {
|
||||||
tT = t
|
tT = t
|
||||||
pkg := os.Getenv("GODOG_TESTED_PACKAGE")
|
pkg := os.Getenv("GODOG_TESTED_PACKAGE")
|
||||||
os.Setenv("GODOG_TESTED_PACKAGE", "github.com/cucumber/godog")
|
os.Setenv("GODOG_TESTED_PACKAGE", "git.golang1.ru/softonik/godog")
|
||||||
|
|
||||||
featureFiles, err := listFmtOutputTestsFeatureFiles()
|
featureFiles, err := listFmtOutputTestsFeatureFiles()
|
||||||
require.Nil(t, err)
|
require.Nil(t, err)
|
||||||
|
|
|
@ -10,9 +10,9 @@ import (
|
||||||
|
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
|
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
"github.com/cucumber/godog/formatters"
|
"git.golang1.ru/softonik/godog/formatters"
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
func init() {
|
func init() {
|
||||||
|
|
|
@ -7,7 +7,7 @@ import (
|
||||||
"sort"
|
"sort"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/cucumber/godog/formatters"
|
"git.golang1.ru/softonik/godog/formatters"
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/cucumber/godog/internal/utils"
|
"git.golang1.ru/softonik/godog/internal/utils"
|
||||||
)
|
)
|
||||||
|
|
||||||
// this zeroes the time throughout whole test suite
|
// this zeroes the time throughout whole test suite
|
||||||
|
|
|
@ -3,8 +3,8 @@ package models_test
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
"github.com/cucumber/godog/internal/testutils"
|
"git.golang1.ru/softonik/godog/internal/testutils"
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -3,8 +3,8 @@ package models
|
||||||
import (
|
import (
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
"github.com/cucumber/godog/internal/utils"
|
"git.golang1.ru/softonik/godog/internal/utils"
|
||||||
)
|
)
|
||||||
|
|
||||||
// TestRunStarted ...
|
// TestRunStarted ...
|
||||||
|
|
|
@ -6,8 +6,8 @@ import (
|
||||||
|
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
|
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
type stepResultStatusTestCase struct {
|
type stepResultStatusTestCase struct {
|
||||||
|
|
|
@ -9,7 +9,7 @@ import (
|
||||||
|
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
|
|
||||||
"github.com/cucumber/godog/formatters"
|
"git.golang1.ru/softonik/godog/formatters"
|
||||||
)
|
)
|
||||||
|
|
||||||
var typeOfBytes = reflect.TypeOf([]byte(nil))
|
var typeOfBytes = reflect.TypeOf([]byte(nil))
|
||||||
|
|
|
@ -11,9 +11,9 @@ import (
|
||||||
|
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
|
|
||||||
"github.com/cucumber/godog"
|
"git.golang1.ru/softonik/godog"
|
||||||
"github.com/cucumber/godog/formatters"
|
"git.golang1.ru/softonik/godog/formatters"
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -13,9 +13,9 @@ import (
|
||||||
gherkin "github.com/cucumber/gherkin/go/v26"
|
gherkin "github.com/cucumber/gherkin/go/v26"
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
|
|
||||||
"github.com/cucumber/godog/internal/flags"
|
"git.golang1.ru/softonik/godog/internal/flags"
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
"github.com/cucumber/godog/internal/tags"
|
"git.golang1.ru/softonik/godog/internal/tags"
|
||||||
)
|
)
|
||||||
|
|
||||||
var pathLineRe = regexp.MustCompile(`:([\d]+)$`)
|
var pathLineRe = regexp.MustCompile(`:([\d]+)$`)
|
||||||
|
|
|
@ -10,7 +10,7 @@ import (
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"github.com/cucumber/godog/internal/parser"
|
"git.golang1.ru/softonik/godog/internal/parser"
|
||||||
"github.com/cucumber/messages-go/v16"
|
"github.com/cucumber/messages-go/v16"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -10,7 +10,7 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
"testing/fstest"
|
"testing/fstest"
|
||||||
|
|
||||||
"github.com/cucumber/godog/internal/storage"
|
"git.golang1.ru/softonik/godog/internal/storage"
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
)
|
)
|
||||||
|
|
|
@ -9,7 +9,7 @@ import (
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
"github.com/hashicorp/go-memdb"
|
"github.com/hashicorp/go-memdb"
|
||||||
|
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
|
@ -7,9 +7,9 @@ import (
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
|
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
"github.com/cucumber/godog/internal/storage"
|
"git.golang1.ru/softonik/godog/internal/storage"
|
||||||
"github.com/cucumber/godog/internal/testutils"
|
"git.golang1.ru/softonik/godog/internal/testutils"
|
||||||
)
|
)
|
||||||
|
|
||||||
func Test_MustGetPickle(t *testing.T) {
|
func Test_MustGetPickle(t *testing.T) {
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
|
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
|
|
||||||
"github.com/cucumber/godog/internal/tags"
|
"git.golang1.ru/softonik/godog/internal/tags"
|
||||||
)
|
)
|
||||||
|
|
||||||
type testcaseF struct {
|
type testcaseF struct {
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
|
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
|
|
||||||
"github.com/cucumber/godog/internal/tags"
|
"git.golang1.ru/softonik/godog/internal/tags"
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@ import (
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
)
|
)
|
||||||
|
|
||||||
// BuildTestFeature creates a feature for testing purpose.
|
// BuildTestFeature creates a feature for testing purpose.
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
package godog
|
package godog
|
||||||
|
|
||||||
import "github.com/cucumber/godog/internal/flags"
|
import "git.golang1.ru/softonik/godog/internal/flags"
|
||||||
|
|
||||||
// Options are suite run options
|
// Options are suite run options
|
||||||
// flags are mapped to these options.
|
// flags are mapped to these options.
|
||||||
|
|
14
run.go
14
run.go
|
@ -18,13 +18,13 @@ import (
|
||||||
|
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
|
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
"github.com/cucumber/godog/formatters"
|
"git.golang1.ru/softonik/godog/formatters"
|
||||||
ifmt "github.com/cucumber/godog/internal/formatters"
|
ifmt "git.golang1.ru/softonik/godog/internal/formatters"
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
"github.com/cucumber/godog/internal/parser"
|
"git.golang1.ru/softonik/godog/internal/parser"
|
||||||
"github.com/cucumber/godog/internal/storage"
|
"git.golang1.ru/softonik/godog/internal/storage"
|
||||||
"github.com/cucumber/godog/internal/utils"
|
"git.golang1.ru/softonik/godog/internal/utils"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
|
@ -11,10 +11,10 @@ import (
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
"github.com/cucumber/godog/internal/formatters"
|
"git.golang1.ru/softonik/godog/internal/formatters"
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
"github.com/cucumber/godog/internal/storage"
|
"git.golang1.ru/softonik/godog/internal/storage"
|
||||||
)
|
)
|
||||||
|
|
||||||
var basicGherkinFeature = `
|
var basicGherkinFeature = `
|
||||||
|
|
|
@ -20,10 +20,10 @@ import (
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
"github.com/cucumber/godog/internal/formatters"
|
"git.golang1.ru/softonik/godog/internal/formatters"
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
"github.com/cucumber/godog/internal/storage"
|
"git.golang1.ru/softonik/godog/internal/storage"
|
||||||
)
|
)
|
||||||
|
|
||||||
func okStep() error {
|
func okStep() error {
|
||||||
|
|
8
suite.go
8
suite.go
|
@ -10,10 +10,10 @@ import (
|
||||||
|
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
|
|
||||||
"github.com/cucumber/godog/formatters"
|
"git.golang1.ru/softonik/godog/formatters"
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
"github.com/cucumber/godog/internal/storage"
|
"git.golang1.ru/softonik/godog/internal/storage"
|
||||||
"github.com/cucumber/godog/internal/utils"
|
"git.golang1.ru/softonik/godog/internal/utils"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
|
|
|
@ -19,12 +19,12 @@ import (
|
||||||
"github.com/stretchr/testify/assert"
|
"github.com/stretchr/testify/assert"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
|
|
||||||
"github.com/cucumber/godog/colors"
|
"git.golang1.ru/softonik/godog/colors"
|
||||||
"github.com/cucumber/godog/internal/formatters"
|
"git.golang1.ru/softonik/godog/internal/formatters"
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
"github.com/cucumber/godog/internal/parser"
|
"git.golang1.ru/softonik/godog/internal/parser"
|
||||||
"github.com/cucumber/godog/internal/storage"
|
"git.golang1.ru/softonik/godog/internal/storage"
|
||||||
"github.com/cucumber/godog/internal/utils"
|
"git.golang1.ru/softonik/godog/internal/utils"
|
||||||
)
|
)
|
||||||
|
|
||||||
// InitializeScenario provides steps for godog suite execution and
|
// InitializeScenario provides steps for godog suite execution and
|
||||||
|
@ -844,7 +844,7 @@ func (tc *godogFeaturesScenario) theRenderOutputWillBe(docstring *DocString) err
|
||||||
actualSuiteCtxReg := regexp.MustCompile(`(suite_context_test\.go|\<autogenerated\>):\d+`)
|
actualSuiteCtxReg := regexp.MustCompile(`(suite_context_test\.go|\<autogenerated\>):\d+`)
|
||||||
|
|
||||||
expectedSuiteCtxFuncReg := regexp.MustCompile(`SuiteContext.func(\d+)`)
|
expectedSuiteCtxFuncReg := regexp.MustCompile(`SuiteContext.func(\d+)`)
|
||||||
actualSuiteCtxFuncReg := regexp.MustCompile(`github.com/cucumber/godog.InitializeScenario.func(\d+)`)
|
actualSuiteCtxFuncReg := regexp.MustCompile(`git.golang1.ru/softonik/godog.InitializeScenario.func(\d+)`)
|
||||||
|
|
||||||
suiteCtxPtrReg := regexp.MustCompile(`\*suiteContext`)
|
suiteCtxPtrReg := regexp.MustCompile(`\*suiteContext`)
|
||||||
|
|
||||||
|
|
|
@ -6,10 +6,10 @@ import (
|
||||||
"reflect"
|
"reflect"
|
||||||
"regexp"
|
"regexp"
|
||||||
|
|
||||||
"github.com/cucumber/godog/formatters"
|
"git.golang1.ru/softonik/godog/formatters"
|
||||||
"github.com/cucumber/godog/internal/builder"
|
"git.golang1.ru/softonik/godog/internal/builder"
|
||||||
"github.com/cucumber/godog/internal/flags"
|
"git.golang1.ru/softonik/godog/internal/flags"
|
||||||
"github.com/cucumber/godog/internal/models"
|
"git.golang1.ru/softonik/godog/internal/models"
|
||||||
messages "github.com/cucumber/messages/go/v21"
|
messages "github.com/cucumber/messages/go/v21"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/cucumber/godog/internal/utils"
|
"git.golang1.ru/softonik/godog/internal/utils"
|
||||||
)
|
)
|
||||||
|
|
||||||
// this zeroes the time throughout whole test suite
|
// this zeroes the time throughout whole test suite
|
||||||
|
|
Загрузка…
Создание таблицы
Сослаться в новой задаче