Skip to content

Commit

Permalink
Split vfs_symlink test in twos.
Browse files Browse the repository at this point in the history
  • Loading branch information
cahirwpz committed Jul 31, 2023
1 parent 2117a7a commit 15cace4
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions bin/utest/vfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ TEST_ADD(vfs_dot_dot_across_fs, 0) {
return 0;
}

static void test_vfs_symlink_basic(void) {
TEST_ADD(vfs_symlink_basic, 0) {
xsymlink("Hello, world!", TESTDIR "/testlink");

char buf[32];
Expand All @@ -237,9 +237,11 @@ static void test_vfs_symlink_basic(void) {
syscall_fail(symlink("Hello, world!", TESTDIR "/testlink"), EEXIST);

xunlink(TESTDIR "/testlink");

return 0;
}

static void test_vfs_symlink_vnr(void) {
TEST_ADD(vfs_symlink_vnr, 0) {
int n;
struct stat sb;
ino_t fileino;
Expand Down Expand Up @@ -292,11 +294,7 @@ static void test_vfs_symlink_vnr(void) {
xunlink(TESTDIR "/blink");

xunlink(TESTDIR "/file");
}

TEST_ADD(vfs_symlink, 0) {
test_vfs_symlink_basic();
test_vfs_symlink_vnr();
return 0;
}

Expand Down

0 comments on commit 15cace4

Please sign in to comment.