Skip to content

Commit

Permalink
Fix formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
steves-canva committed May 27, 2024
1 parent 78612a5 commit 6f7d8c4
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 8 deletions.
4 changes: 2 additions & 2 deletions testbed/testbed/multi_receiver_test_case.go
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,7 @@ func (tc *MultiReceiverTestCase) Sleep(d time.Duration) {
// if time is out and condition does not become true. If error is signaled
// while waiting the function will return false, but will not record additional
// test error (we assume that signaled error is already recorded in indicateError()).
func (tc *MultiReceiverTestCase) WaitForN(cond func() bool, duration time.Duration, errMsg interface{}) bool {
func (tc *MultiReceiverTestCase) WaitForN(cond func() bool, duration time.Duration, errMsg any) bool {
startTime := time.Now()

// Start with 5 ms waiting interval between condition re-evaluation.
Expand Down Expand Up @@ -281,7 +281,7 @@ func (tc *MultiReceiverTestCase) WaitForN(cond func() bool, duration time.Durati
}

// WaitFor is like WaitForN but with a fixed duration of 10 seconds
func (tc *MultiReceiverTestCase) WaitFor(cond func() bool, errMsg interface{}) bool {
func (tc *MultiReceiverTestCase) WaitFor(cond func() bool, errMsg any) bool {
return tc.WaitForN(cond, time.Second*60, errMsg)
}

Expand Down
9 changes: 4 additions & 5 deletions testbed/testbed/multi_receiver_validator.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,14 @@ type MultiReceiverTestCaseValidator struct {
assertionFailures []*TraceAssertionFailure
}


func NewMultiReceiverTestCaseValidator(
senderName string,
provider DataProvider,
validator func(tc *MultiReceiverTestCase),
senderName string,

Check failure on line 16 in testbed/testbed/multi_receiver_validator.go

View workflow job for this annotation

GitHub Actions / lint-matrix (windows, other)

unused-parameter: parameter 'senderName' seems to be unused, consider removing or renaming it as _ (revive)

Check failure on line 16 in testbed/testbed/multi_receiver_validator.go

View workflow job for this annotation

GitHub Actions / lint-matrix (linux, other)

unused-parameter: parameter 'senderName' seems to be unused, consider removing or renaming it as _ (revive)
provider DataProvider,
validator func(tc *MultiReceiverTestCase),
) *MultiReceiverTestCaseValidator {
return &MultiReceiverTestCaseValidator{
dataProvider: provider,
Validate: validator,
Validate: validator,
}
}

Expand Down
2 changes: 1 addition & 1 deletion testbed/testbed/results.go
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,7 @@ func (r *MultiReceiverTestResults) Init(resultsDir string) {
"----------------------------------------------------------------------|------|-------:|------------:|\n")
}

func (r *MultiReceiverTestResults) Add(_ string, result interface{}) {
func (r *MultiReceiverTestResults) Add(_ string, result any) {
testResult, ok := result.(*MultiReceiverTestResult)
if !ok {
return
Expand Down

0 comments on commit 6f7d8c4

Please sign in to comment.