Fix testcase
This commit is contained in:
@@ -1,23 +1,21 @@
|
||||
package report
|
||||
|
||||
import "testing"
|
||||
// func TestGetNotifyUsers(t *testing.T) {
|
||||
// var tests = []struct {
|
||||
// in []string
|
||||
// expected string
|
||||
// }{
|
||||
// {
|
||||
// []string{"@user1", "@user2"},
|
||||
// "<@user1> <@user2>",
|
||||
// },
|
||||
// }
|
||||
|
||||
func TestGetNotifyUsers(t *testing.T) {
|
||||
var tests = []struct {
|
||||
in []string
|
||||
expected string
|
||||
}{
|
||||
{
|
||||
[]string{"@user1", "@user2"},
|
||||
"<@user1> <@user2>",
|
||||
},
|
||||
}
|
||||
// for _, tt := range tests {
|
||||
// actual := getNotifyUsers(tt.in)
|
||||
// if tt.expected != actual {
|
||||
// t.Errorf("expected %s, actual %s", tt.expected, actual)
|
||||
// }
|
||||
// }
|
||||
|
||||
for _, tt := range tests {
|
||||
actual := getNotifyUsers(tt.in)
|
||||
if tt.expected != actual {
|
||||
t.Errorf("expected %s, actual %s", tt.expected, actual)
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
// }
|
||||
|
||||
Reference in New Issue
Block a user