Switch to using the dep tool and update all the dependencies
This commit is contained in:
parent
5135ff73cb
commit
98c2d2c41b
5321 changed files with 4483201 additions and 5922 deletions
37
vendor/github.com/aws/aws-sdk-go/service/machinelearning/customizations_test.go
generated
vendored
Normal file
37
vendor/github.com/aws/aws-sdk-go/service/machinelearning/customizations_test.go
generated
vendored
Normal file
|
@ -0,0 +1,37 @@
|
|||
package machinelearning_test
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"testing"
|
||||
|
||||
"github.com/stretchr/testify/assert"
|
||||
|
||||
"github.com/aws/aws-sdk-go/aws"
|
||||
"github.com/aws/aws-sdk-go/aws/request"
|
||||
"github.com/aws/aws-sdk-go/awstesting/unit"
|
||||
"github.com/aws/aws-sdk-go/service/machinelearning"
|
||||
)
|
||||
|
||||
func TestPredictEndpoint(t *testing.T) {
|
||||
ml := machinelearning.New(unit.Session)
|
||||
ml.Handlers.Send.Clear()
|
||||
ml.Handlers.Send.PushBack(func(r *request.Request) {
|
||||
r.HTTPResponse = &http.Response{
|
||||
StatusCode: 200,
|
||||
Header: http.Header{},
|
||||
Body: ioutil.NopCloser(bytes.NewReader([]byte("{}"))),
|
||||
}
|
||||
})
|
||||
|
||||
req, _ := ml.PredictRequest(&machinelearning.PredictInput{
|
||||
PredictEndpoint: aws.String("https://localhost/endpoint"),
|
||||
MLModelId: aws.String("id"),
|
||||
Record: map[string]*string{},
|
||||
})
|
||||
err := req.Send()
|
||||
|
||||
assert.Nil(t, err)
|
||||
assert.Equal(t, "https://localhost/endpoint", req.HTTPRequest.URL.String())
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue