Skip to content

Commit

Permalink
Add doc
Browse files Browse the repository at this point in the history
Signed-off-by: Maxime Soulé <btik-git@scoubidou.com>
  • Loading branch information
maxatome committed Jun 18, 2018
1 parent 822ae5d commit cf0b4e1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions td_code.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,8 @@ var _ TestDeep = &tdCode{}
// confusion produced by output in case of failure. When the data
// needs to be transformed before being compared again, Smuggle
// operator should be used instead.
//
// TypeBehind method returns the reflect.Type of only parameter of "fn".
func Code(fn interface{}) TestDeep {
vfn := reflect.ValueOf(fn)

Expand Down
2 changes: 2 additions & 0 deletions td_smuggle.go
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,8 @@ var _ TestDeep = &tdSmuggle{}
// The difference between Smuggle and Code operators is that Code is
// used to do a final comparison while Smuggle transforms the data and
// then steps down in favor of generic comparison process.
//
// TypeBehind method returns the reflect.Type of only parameter of "fn".
func Smuggle(fn interface{}, expectedValue interface{}) TestDeep {
vfn := reflect.ValueOf(fn)

Expand Down

0 comments on commit cf0b4e1

Please sign in to comment.