github.com/go-playground/pkg/v5@v5.29.1/strings/join_test.go (about)

     1  package stringsext
     2  
     3  import (
     4  	"strings"
     5  	"testing"
     6  )
     7  
     8  func TestJoin(t *testing.T) {
     9  	s1, s2, s3 := "a", "b", "c"
    10  	arr := []string{s1, s2, s3}
    11  	if strings.Join(arr, ",") != Join(",", s1, s2, s3) {
    12  		t.Errorf("Join failed")
    13  	}
    14  }