Skip to content

Commit

Permalink
Merge pull request #1 from dasrick/rename-interface
Browse files Browse the repository at this point in the history
rename interface
  • Loading branch information
dasrick authored May 2, 2019
2 parents 2b732f4 + 7906c68 commit bc0163b
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 48 deletions.
20 changes: 3 additions & 17 deletions Gopkg.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ To import this package, add the following line to your code:
import "gopkg.in/dasrick/go-teams-notify.v1"
```

And this is an example of a simple implemenatation ...
And this is an example of a simple implementation ...

```
import (
Expand Down
26 changes: 0 additions & 26 deletions mocks/Client.go

This file was deleted.

6 changes: 3 additions & 3 deletions send.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ import (
"time"
)

// Client - interface of MS Teams notify
type Client interface {
// API - interface of MS Teams notify
type API interface {
Send(webhookURL string, webhookMessage MessageCard) error
}

Expand All @@ -21,7 +21,7 @@ type teamsClient struct {
}

// NewClient - create a brand new client for MS Teams notify
func NewClient() (Client, error) {
func NewClient() (API, error) {
client := teamsClient{
httpClient: &http.Client{
Timeout: 5 * time.Second,
Expand Down
2 changes: 1 addition & 1 deletion send_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ func (f RoundTripFunc) RoundTrip(req *http.Request) (*http.Response, error) {
return f(req)
}

//NewTestClient returns *http.Client with Transport replaced to avoid making real calls
//NewTestClient returns *http.API with Transport replaced to avoid making real calls
func NewTestClient(fn RoundTripFunc) *http.Client {
return &http.Client{
Transport: RoundTripFunc(fn),
Expand Down

0 comments on commit bc0163b

Please sign in to comment.