|
|
@ -354,6 +354,15 @@ symlink_existing_dir(Config) -> |
|
|
|
|
|
|
|
ok = rebar_file_utils:symlink_or_create_dir(Source, Target), |
|
|
|
|
|
|
|
%% `Target' should be a symlink, and `Source' |
|
|
|
%% should exist |
|
|
|
?assert(ec_file:is_dir(Target)), |
|
|
|
?assert(ec_file:is_symlink(Target)), |
|
|
|
?assert(ec_file:is_dir(Source)), |
|
|
|
|
|
|
|
%% repeat to check for idempotence |
|
|
|
ok = rebar_file_utils:symlink_or_create_dir(Source, Target), |
|
|
|
|
|
|
|
%% `Target' should be a symlink, and `Source' |
|
|
|
%% should exist |
|
|
|
?assert(ec_file:is_dir(Target)), |
|
|
@ -373,6 +382,15 @@ preserve_existing_symlink(Config) -> |
|
|
|
|
|
|
|
ok = rebar_file_utils:symlink_or_create_dir(Source, Target), |
|
|
|
|
|
|
|
%% `Target' should be a symlink, and `Source' |
|
|
|
%% should exist |
|
|
|
?assert(ec_file:is_dir(Target)), |
|
|
|
?assert(ec_file:is_symlink(Target)), |
|
|
|
?assert(ec_file:is_dir(Source)), |
|
|
|
|
|
|
|
%% repeat to check for idempotence |
|
|
|
ok = rebar_file_utils:symlink_or_create_dir(Source, Target), |
|
|
|
|
|
|
|
%% `Target' should be a symlink, and `Source' |
|
|
|
%% should exist |
|
|
|
?assert(ec_file:is_dir(Target)), |
|
|
@ -388,6 +406,15 @@ create_missing_dir(Config) -> |
|
|
|
|
|
|
|
ok = rebar_file_utils:symlink_or_create_dir(Source, Target), |
|
|
|
|
|
|
|
%% `Target' should be a directory not a symlink, and `Source' |
|
|
|
%% should not exist |
|
|
|
?assert(ec_file:is_dir(Target)), |
|
|
|
?assert(not ec_file:is_symlink(Target)), |
|
|
|
?assert(not ec_file:is_dir(Source)), |
|
|
|
|
|
|
|
%% repeat to check for idempotence |
|
|
|
ok = rebar_file_utils:symlink_or_create_dir(Source, Target), |
|
|
|
|
|
|
|
%% `Target' should be a directory not a symlink, and `Source' |
|
|
|
%% should not exist |
|
|
|
?assert(ec_file:is_dir(Target)), |
|
|
@ -405,6 +432,15 @@ preserve_existing_dir(Config) -> |
|
|
|
|
|
|
|
ok = rebar_file_utils:symlink_or_create_dir(Source, Target), |
|
|
|
|
|
|
|
%% `Target' should be a directory, and `Source' |
|
|
|
%% should not exist |
|
|
|
?assert(ec_file:is_dir(Target)), |
|
|
|
?assert(not ec_file:is_symlink(Target)), |
|
|
|
?assert(not ec_file:is_dir(Source)), |
|
|
|
|
|
|
|
%% repeat to check for idempotence |
|
|
|
ok = rebar_file_utils:symlink_or_create_dir(Source, Target), |
|
|
|
|
|
|
|
%% `Target' should be a directory, and `Source' |
|
|
|
%% should not exist |
|
|
|
?assert(ec_file:is_dir(Target)), |
|
|
@ -431,6 +467,15 @@ delete_symlink_and_create_dir(Config) -> |
|
|
|
|
|
|
|
ok = rebar_file_utils:symlink_or_create_dir(Source, Target), |
|
|
|
|
|
|
|
%% `Target' should be a directory not a symlink, and `Source' |
|
|
|
%% should not exist |
|
|
|
?assert(not ec_file:is_symlink(Target)), |
|
|
|
?assert(ec_file:is_dir(Target)), |
|
|
|
?assert(not ec_file:is_dir(Source)), |
|
|
|
|
|
|
|
%% repeat to check for idempotence |
|
|
|
ok = rebar_file_utils:symlink_or_create_dir(Source, Target), |
|
|
|
|
|
|
|
%% `Target' should be a directory not a symlink, and `Source' |
|
|
|
%% should not exist |
|
|
|
?assert(not ec_file:is_symlink(Target)), |
|
|
@ -453,6 +498,15 @@ delete_dir_and_create_symlink(Config) -> |
|
|
|
|
|
|
|
ok = rebar_file_utils:symlink_or_create_dir(Source, Target), |
|
|
|
|
|
|
|
%% `Target' should be a symlink not a directory, and `Source' |
|
|
|
%% should exist |
|
|
|
?assert(ec_file:is_dir(Target)), |
|
|
|
?assert(ec_file:is_symlink(Target)), |
|
|
|
?assert(ec_file:is_dir(Source)), |
|
|
|
|
|
|
|
%% repeat to check for idempotence |
|
|
|
ok = rebar_file_utils:symlink_or_create_dir(Source, Target), |
|
|
|
|
|
|
|
%% `Target' should be a symlink not a directory, and `Source' |
|
|
|
%% should exist |
|
|
|
?assert(ec_file:is_dir(Target)), |
|
|
|