1
0
mirror of https://github.com/fumiama/go-nd-portal.git synced 2026-06-27 06:30:27 +08:00
This commit is contained in:
源文雨
2022-11-26 00:39:38 +08:00
parent 2dd688a7d9
commit 8743bf9b5d
8 changed files with 361 additions and 0 deletions

15
base64_test.go Normal file
View File

@@ -0,0 +1,15 @@
package gondportal
import (
"encoding/base64"
"strings"
"testing"
"github.com/stretchr/testify/assert"
)
func TestBase64(t *testing.T) {
buf := strings.Builder{}
base64.NewEncoder(Base64Encoding, &buf).Write([]byte("123456"))
assert.Equal(t, "9F2z0JHI", buf.String())
}