Skip to content

Commit

Permalink
remove some unnecessary changes
Browse files Browse the repository at this point in the history
  • Loading branch information
knusbaum committed Sep 4, 2020
1 parent 3a20589 commit b27b8e1
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 15 deletions.
10 changes: 0 additions & 10 deletions ddtrace/tracer/option_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,6 @@ import (
"github.com/stretchr/testify/assert"
)

// withTransportSendError will cause err to be returned on any call to (transport).send()
// if the tracer is configured with a dummyTransport,
func withTransportSendError(err error) StartOption {
return func(c *config) {
if t, ok := c.transport.(*dummyTransport); ok {
t.sendError = err
}
}
}

func withTransport(t transport) StartOption {
return func(c *config) {
c.transport = t
Expand Down
6 changes: 1 addition & 5 deletions ddtrace/tracer/tracer_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1150,8 +1150,7 @@ func startTestTracer(t interface {
// Mock Transport with a real Encoder
type dummyTransport struct {
sync.RWMutex
traces spanLists
sendError error
traces spanLists
}

func newDummyTransport() *dummyTransport {
Expand All @@ -1165,9 +1164,6 @@ func (t *dummyTransport) Len() int {
}

func (t *dummyTransport) send(p *payload) (io.ReadCloser, error) {
if t.sendError != nil {
return nil, t.sendError
}
traces, err := decode(p)
if err != nil {
return nil, err
Expand Down

0 comments on commit b27b8e1

Please sign in to comment.