mirror of
https://github.com/httprunner/httprunner.git
synced 2026-09-08 00:47:36 +08:00
change: remove namespace
This commit is contained in:
@@ -1,9 +1,7 @@
|
||||
package boomer
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"math"
|
||||
"sort"
|
||||
"testing"
|
||||
)
|
||||
|
||||
@@ -108,27 +106,3 @@ func TestConsoleOutput(t *testing.T) {
|
||||
|
||||
o.OnStop()
|
||||
}
|
||||
|
||||
func TestSortString(t *testing.T) {
|
||||
|
||||
stats := []struct {
|
||||
method string
|
||||
name string
|
||||
}{
|
||||
{"transaction", "Action"},
|
||||
{"request-GET", "get with params"},
|
||||
{"request-POST", "post form data"},
|
||||
{"request-POST", "post json data"},
|
||||
{"transaction", "tran1"},
|
||||
}
|
||||
|
||||
sort.Slice(stats, func(i, j int) bool {
|
||||
if stats[i].method < stats[j].method {
|
||||
return true
|
||||
}
|
||||
|
||||
return stats[i].name < stats[j].name
|
||||
})
|
||||
|
||||
fmt.Println(stats)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user