Merge remote-tracking branch 'upstream/master' into discord

Этот коммит содержится в:
Simon Mikulcik 2020-02-07 15:31:54 -06:00
родитель 3c03e25725 deccedda1c
коммит 09be91ff9a
4 изменённых файлов: 18 добавлений и 16 удалений

Просмотреть файл

@ -22,6 +22,8 @@ This document is formatted according to the principles of [Keep A CHANGELOG](htt
### Fixed
- Find/Replaced references to DATA-DOG/godog -> cucumber/godog for docs. ([smikulcik])
## [0.8.0]
### Added

Просмотреть файл

@ -1,6 +1,6 @@
[![CircleCI](https://circleci.com/gh/cucumber/godog/tree/master.svg?style=svg)](https://circleci.com/gh/cucumber/godog/tree/master)
[![GoDoc](https://godoc.org/github.com/DATA-DOG/godog?status.svg)](https://godoc.org/github.com/DATA-DOG/godog)
[![codecov.io](https://codecov.io/github/DATA-DOG/godog/branch/master/graph/badge.svg)](https://codecov.io/github/DATA-DOG/godog)
[![GoDoc](https://godoc.org/github.com/cucumber/godog?status.svg)](https://godoc.org/github.com/cucumber/godog)
[![codecov.io](https://codecov.io/github/cucumber/godog/branch/master/graph/badge.svg)](https://codecov.io/github/cucumber/godog)
# Godog
@ -12,7 +12,7 @@
Please read all the README, you may find it very useful. And do not forget
to peek into the
[CHANGELOG](https://github.com/DATA-DOG/godog/blob/master/CHANGELOG.md)
[CHANGELOG](https://github.com/cucumber/godog/blob/master/CHANGELOG.md)
from time to time.
Package godog is the official Cucumber BDD framework for Golang, it merges
@ -64,7 +64,7 @@ themselves from costly regressions.
## Install
go get github.com/DATA-DOG/godog/cmd/godog
go get github.com/cucumber/godog/cmd/godog
## Example
@ -108,7 +108,7 @@ undefined:
If we wish to vendor godog dependency, we can do it as usual, using tools
you prefer:
git clone https://github.com/DATA-DOG/godog.git $GOPATH/src/godogs/vendor/github.com/DATA-DOG/godog
git clone https://github.com/cucumber/godog.git $GOPATH/src/godogs/vendor/github.com/cucumber/godog
It gives you undefined step snippets to implement in your test context.
You may copy these snippets into your `godogs_test.go` file.
@ -153,7 +153,7 @@ package main
import (
"fmt"
"github.com/DATA-DOG/godog"
"github.com/cucumber/godog"
)
func thereAreGodogs(available int) error {
@ -213,7 +213,7 @@ composed.
image](https://github.com/myie/cucumber-html-reporter) for usage
details.
- [how to use godog by semaphoreci](https://semaphoreci.com/community/tutorials/how-to-use-godog-for-behavior-driven-development-in-go)
- see [examples](https://github.com/DATA-DOG/godog/tree/master/examples)
- see [examples](https://github.com/cucumber/godog/tree/master/examples)
- see extension [AssistDog](https://github.com/hellomd/assistdog), which
may have useful **gherkin.DataTable** transformations or comparison
methods for assertions.
@ -380,7 +380,7 @@ Join [here](https://cucumberbdd-slack-invite.herokuapp.com/).
**Gherkin** is licensed under the [MIT][license] and developed as
a part of the [cucumber project][cucumber]
[godoc]: http://godoc.org/github.com/DATA-DOG/godog "Documentation on godoc"
[godoc]: http://godoc.org/github.com/cucumber/godog "Documentation on godoc"
[golang]: https://golang.org/ "GO programming language"
[behat]: http://docs.behat.org/ "Behavior driven development framework for PHP"
[cucumber]: https://cucumber.io/ "Behavior driven development framework"

Просмотреть файл

@ -44,7 +44,7 @@ Now we have described a success case and an error when the request method is not
Run **godog version.feature**. You should see the following result, which says that all of our
steps are yet undefined and provide us with the snippets to implement them.
![Screenshot](https://raw.github.com/DATA-DOG/godog/master/examples/api/screenshots/undefined.png)
![Screenshot](https://raw.github.com/cucumber/godog/master/examples/api/screenshots/undefined.png)
### Step 3
@ -56,8 +56,8 @@ need to store state within steps (a response), we should introduce a structure w
package main
import (
"github.com/DATA-DOG/godog"
"github.com/DATA-DOG/godog/gherkin"
"github.com/cucumber/godog"
"github.com/cucumber/godog/gherkin"
)
type apiFeature struct {
@ -98,8 +98,8 @@ import (
"net/http"
"net/http/httptest"
"github.com/DATA-DOG/godog"
"github.com/DATA-DOG/godog/gherkin"
"github.com/cucumber/godog"
"github.com/cucumber/godog/gherkin"
)
type apiFeature struct {
@ -192,7 +192,7 @@ import (
"fmt"
"net/http"
"github.com/DATA-DOG/godog"
"github.com/cucumber/godog"
)
func getVersion(w http.ResponseWriter, r *http.Request) {
@ -253,7 +253,7 @@ used to respond with the correct constant version number.
Run our tests to see whether everything is happening as we have expected: `godog version.feature`
![Screenshot](https://raw.github.com/DATA-DOG/godog/master/examples/api/screenshots/passed.png)
![Screenshot](https://raw.github.com/cucumber/godog/master/examples/api/screenshots/passed.png)
### Conclusions

Просмотреть файл

@ -1,7 +1,7 @@
# An example of API with DB
The following example demonstrates steps how we describe and test our API with DB using **godog**.
To start with, see [API example](https://github.com/DATA-DOG/godog/tree/master/examples/api) before.
To start with, see [API example](https://github.com/cucumber/godog/tree/master/examples/api) before.
We have extended it to be used with database.
The interesting point is, that we have [go-txdb](https://github.com/DATA-DOG/go-txdb) library,