mirror of
https://github.com/casdoor/casdoor.git
synced 2025-07-03 04:10:20 +08:00
Add user.UpdateUserHash()
This commit is contained in:
@ -45,6 +45,20 @@ func TestSyncIds(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
func TestSyncHashes(t *testing.T) {
|
||||
InitConfig()
|
||||
|
||||
users := GetGlobalUsers()
|
||||
for _, user := range users {
|
||||
if user.Hash != "" {
|
||||
continue
|
||||
}
|
||||
|
||||
user.UpdateUserHash()
|
||||
updateUserColumn("hash", user)
|
||||
}
|
||||
}
|
||||
|
||||
func TestGetSaltedPassword(t *testing.T) {
|
||||
password := "123456"
|
||||
salt := "123"
|
||||
|
Reference in New Issue
Block a user