package token

import (
	"fmt"
	"testing"

	"github.com/gogf/gf/v2/os/gctx"
)

func TestParseUserToken(t *testing.T) {
	token, err := ParseUserToken(gctx.New(), "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJVc2VySUQiOiJiZjVlYjUwODdiYTY0Nzg4YjI2ODVkNjc1ZDQxNTdhNCIsIlVzZXJuYW1lIjoiZGVtbyIsImlzcyI6IkF1dGggU2VydmVyIiwic3ViIjoiZGVtbyIsImV4cCI6MTcyMDI4NTI1MCwibmJmIjoxNzIwMjc0NDUxLCJpYXQiOjE3MjAyNzQ0NTAsImp0aSI6IjVmYmNlZDllLTUxMjEtNDFhYi05NTAzLTcwNDBjZGYyYzg5YSJ9.NRNgvmqIRczESViDnSczQBpmhC3oPM41HVnEqzK7Npk")
	if err != nil {
		fmt.Printf("err:%v\n", err)
	}
	fmt.Printf("token:%+v\n", token)
}
