1
0
mirror of https://github.com/drakkan/sftpgo.git synced 2025-11-29 22:08:10 +02:00

fix misspells and ineffectual assignments

This commit is contained in:
Nicola Murino
2019-07-20 21:17:53 +02:00
parent 1019d74243
commit 22b8dc7f1d
7 changed files with 33 additions and 18 deletions

View File

@@ -153,7 +153,7 @@ func TestUpdateUserNoCredentials(t *testing.T) {
}
user.Password = ""
user.PublicKey = ""
// password and public key will be ommitted from json serialization if empty and so they will remain unchanged
// password and public key will be omitted from json serialization if empty and so they will remain unchanged
// and no validation error will be raised
_, err = api.UpdateUser(user, http.StatusOK)
if err != nil {
@@ -252,10 +252,16 @@ func TestGetUsers(t *testing.T) {
t.Errorf("at least 2 users are expected")
}
users, err = api.GetUsers(1, 0, "", http.StatusOK)
if err != nil {
t.Errorf("unable to get users: %v", err)
}
if len(users) != 1 {
t.Errorf("1 user are expected")
}
users, err = api.GetUsers(1, 1, "", http.StatusOK)
if err != nil {
t.Errorf("unable to get users: %v", err)
}
if len(users) != 1 {
t.Errorf("1 user are expected")
}