Skip to content

Commit

Permalink
Fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
wenovus committed Dec 3, 2023
1 parent 1695a27 commit c4c3264
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 15 deletions.
4 changes: 2 additions & 2 deletions internal/gnmitestutil/gnmi.go
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,8 @@ func (g *FakeGNMI) Requests() []*gpb.SubscribeRequest {
return g.agent.Requests()
}

// Requests returns the request-scoped values from the last ygnmi request sent
// to the gNMI server.
// LastRequestContextValues returns the request-scoped values from the last
// ygnmi request sent to the gNMI server.
func (g *FakeGNMI) LastRequestContextValues() *ygnmi.RequestValues {
return g.clientWrapper.requestValues
}
Expand Down
13 changes: 0 additions & 13 deletions ygnmi/path_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -115,19 +115,6 @@ func ResolvePath(n PathStruct) (*gpb.Path, map[string]interface{}, error) {
return &gpb.Path{Elem: p}, root.CustomData(), nil
}

// MustPath calls ResolvePath and panics on error.
// It is intended for use in tests with generated PathStructs.
//
// ygnmi.MustResolvePath(ocpath.Interface("port0").Name().Config().PathStruct())
// returns "/interfaces/interface[name=port0]/config/name
func MustPath(q UntypedQuery) *gpb.Path {
p, _, err := ResolvePath(q.PathStruct())
if err != nil {
panic(err)
}
return p
}

// ResolveRelPath returns the partial []*gpb.PathElem representing the
// PathStruct's relative path.
func ResolveRelPath(n PathStruct) ([]*gpb.PathElem, []error) {
Expand Down

0 comments on commit c4c3264

Please sign in to comment.