Unverified Commit b18afc9e authored by catsby's avatar catsby
Browse files

snapshot

parent 6f55b4c2
Branches unavailable
No related merge requests found
Showing with 529 additions and 20 deletions
+529 -20
......@@ -5,16 +5,16 @@ go 1.13
replace github.com/hashicorp/vault/sdk => ../sdk
require (
github.com/go-test/deep v1.0.2-0.20181118220953-042da051cf31
github.com/go-test/deep v1.0.2
github.com/hashicorp/errwrap v1.0.0
github.com/hashicorp/go-cleanhttp v0.5.1
github.com/hashicorp/go-multierror v1.0.0
github.com/hashicorp/go-retryablehttp v0.6.2
github.com/hashicorp/go-rootcerts v1.0.1
github.com/hashicorp/go-rootcerts v1.0.2
github.com/hashicorp/hcl v1.0.0
github.com/hashicorp/vault/sdk v0.1.14-0.20200215195600-2ca765f0a500
github.com/hashicorp/vault/sdk v0.1.14-0.20200429182704-29fce8f27ce4
github.com/mitchellh/mapstructure v1.1.2
golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7
golang.org/x/net v0.0.0-20200114155413-6afb5195e5aa
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4
gopkg.in/square/go-jose.v2 v2.3.1
gopkg.in/square/go-jose.v2 v2.4.1
)
This diff is collapsed.
......@@ -310,21 +310,15 @@ func Run(tt TestT, c Case) {
// or not. Set the err to nil. If the error is a logical.ErrorResponse,
// it will be handled later.
if s.ErrorOk {
// err = nil
q.Q("===> error ok, setting to nil")
err = nil
} else {
// // If the error is not expected, fail right away.
// tt.Error(fmt.Sprintf("Failed step %d: %s", i+1, err))
// break
tt.Error(fmt.Sprintf("Failed step %d: %s", i+1, err))
break
}
}
// If the error is a 'logical.ErrorResponse' and if error was not expected,
// set the error so that this can be caught below.
// TODO resp error check
// if resp.IsError() && !s.ErrorOk {
// err = fmt.Errorf("erroneous response:\n\n%#v", resp)
// }
// TODO
// - test check func here
//
......@@ -335,11 +329,11 @@ func Run(tt TestT, c Case) {
// TODO: This works perfectly for now, but it would be better if 'Check'
// function takes in both the response object and the error, and decide on
// the action on its own.
// if err == nil && s.Check != nil {
// // Call the test method
// // TODO check here
// // err = s.Check(resp)
// }
if err == nil && s.Check != nil {
// Call the test method
// TODO check here
err = s.Check(resp)
}
if err != nil {
tt.Error(fmt.Sprintf("Failed step %d: %s", i+1, err))
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment