Skip to content

Commit

Permalink
tests UPDATE handle custom umask
Browse files Browse the repository at this point in the history
  • Loading branch information
michalvasko committed Jul 23, 2024
1 parent a80546c commit 3a066c9
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions tests/test_plugin.c
Original file line number Diff line number Diff line change
Expand Up @@ -1141,6 +1141,11 @@ test_access_get(void **state)
char *username_out = NULL, *groupname_out = NULL;
mode_t perm;

if (SR_UMASK) {
puts("Custom Sysrepo umask affects the test. Skipping.");
return;
}

rc = testutil_uid2usr(getuid(), &username);
assert_int_equal(rc, SR_ERR_OK);

Expand Down Expand Up @@ -1186,6 +1191,11 @@ test_access_setandget(void **state)
char *username_out = NULL, *groupname_out = NULL;
mode_t perm;

if (SR_UMASK) {
puts("Custom Sysrepo umask affects the test. Skipping.");
return;
}

rc = testutil_uid2usr(getuid(), &username);
assert_int_equal(rc, SR_ERR_OK);

Expand Down

0 comments on commit 3a066c9

Please sign in to comment.