@@ -21,6 +21,7 @@ subroutine collect_filesystem(testsuite)
21
21
new_unittest(" fs_file_not_exists" , fs_file_not_exists, should_fail= .true. ), &
22
22
new_unittest(" fs_file_exists" , fs_file_exists), &
23
23
new_unittest(" fs_current_dir_exists" , fs_current_dir_exists), &
24
+ new_unittest(" fs_path_separator" , fs_path_separator), &
24
25
new_unittest(" fs_run_invalid_command" , fs_run_invalid_command, should_fail= .true. ), &
25
26
new_unittest(" fs_run_with_invalid_option" , fs_run_with_invalid_option, should_fail= .true. ), &
26
27
new_unittest(" fs_run_valid_command" , fs_run_valid_command), &
@@ -80,6 +81,21 @@ subroutine fs_current_dir_exists(error)
80
81
call check(error, is_existing, " Current directory should not fail." )
81
82
end
82
83
84
+ subroutine fs_path_separator (error )
85
+ type (error_type), allocatable , intent (out ) :: error
86
+
87
+ character (* ), parameter :: outer_dir = " path_separator_outer"
88
+ character (* ), parameter :: inner_dir = " path_separator_inner"
89
+
90
+ call rmdir(outer_dir)
91
+ call check(error, .not. exists(outer_dir), " Directory should not exist." )
92
+ call mkdir(outer_dir)
93
+ call check(error, exists(outer_dir), " Outer directory should now exist." )
94
+ call mkdir(outer_dir// path_separator()// inner_dir)
95
+ call check(error, exists(outer_dir// path_separator()// inner_dir), " Inner directory should now exist." )
96
+ call rmdir(outer_dir)
97
+ end
98
+
83
99
subroutine fs_run_invalid_command (error )
84
100
type (error_type), allocatable , intent (out ) :: error
85
101
0 commit comments