Test go-gin-server sample with go test -v (#8855)

* test go gin sample with `go test -v`

* install via go get

* update main.mustache
This commit is contained in:
William Cheng
2021-03-02 11:07:25 +08:00
committed by GitHub
parent f7b2baf38e
commit 07f8bde6c1
3 changed files with 10 additions and 10 deletions

View File

@@ -9,7 +9,7 @@ import (
// once you place this file into your project. // once you place this file into your project.
// For example, // For example,
// //
// sw "github.com/myname/myrepo/{{apiPath}}" //sw "github.com/{{{gitUserId}}}/{{{gitRepoId}}}/{{{apiPath}}}"
// //
sw "./{{apiPath}}" sw "./{{apiPath}}"
) )

View File

@@ -17,7 +17,7 @@ import (
// once you place this file into your project. // once you place this file into your project.
// For example, // For example,
// //
// sw "github.com/myname/myrepo/go" //sw "github.com/GIT_USER_ID/GIT_REPO_ID/go"
// //
sw "./go" sw "./go"
) )

View File

@@ -27,30 +27,30 @@
<version>1.2.1</version> <version>1.2.1</version>
<executions> <executions>
<execution> <execution>
<id>gofmt-test</id> <id>go-get</id>
<phase>integration-test</phase> <phase>integration-test</phase>
<goals> <goals>
<goal>exec</goal> <goal>exec</goal>
</goals> </goals>
<configuration> <configuration>
<executable>gofmt</executable> <executable>go</executable>
<arguments> <arguments>
<argument>-w</argument> <argument>get</argument>
<argument>./main.go</argument> <argument>github.com/gin-gonic/gin</argument>
</arguments> </arguments>
</configuration> </configuration>
</execution> </execution>
<execution> <execution>
<id>gofmt-file-test</id> <id>go-test</id>
<phase>integration-test</phase> <phase>integration-test</phase>
<goals> <goals>
<goal>exec</goal> <goal>exec</goal>
</goals> </goals>
<configuration> <configuration>
<executable>gofmt</executable> <executable>go</executable>
<arguments> <arguments>
<argument>-w</argument> <argument>test</argument>
<argument>./go/</argument> <argument>-v</argument>
</arguments> </arguments>
</configuration> </configuration>
</execution> </execution>