Fossil SCM
Disable "longpath" testcase for non-unix platforms. Make sure temporary directories created by the testcase are cleaned up.
Commit
46dc6537f84823860e9c48cc4ec513250852388e
Parent
ab047fc478320a5…
1 file changed
+6
-4
+6
-4
| --- test/longpath.test | ||
| +++ test/longpath.test | ||
| @@ -1,10 +1,14 @@ | ||
| 1 | 1 | # |
| 2 | 2 | # Tests using a repo path >512 chars. |
| 3 | 3 | # |
| 4 | 4 | # This test should pass on any platform. |
| 5 | 5 | # |
| 6 | + | |
| 7 | +if {$::tcl_platform(platform)!="unix"} { | |
| 8 | + exit | |
| 9 | +} | |
| 6 | 10 | |
| 7 | 11 | # Fossil will write data on $HOME, running 'fossil new' here. |
| 8 | 12 | # We need not to clutter the $HOME of the test caller. |
| 9 | 13 | # |
| 10 | 14 | set env(HOME) [pwd] |
| @@ -11,16 +15,14 @@ | ||
| 11 | 15 | |
| 12 | 16 | # Create the repo |
| 13 | 17 | # |
| 14 | 18 | set x [string repeat x 240] |
| 15 | 19 | set longpath [pwd]/$x/$x |
| 16 | -file mkdir [pwd]/$x | |
| 17 | 20 | file mkdir $longpath |
| 18 | 21 | |
| 19 | 22 | test longpath-test.1 { |
| 20 | 23 | ![regexp CANTOPEN [fossil new $longpath/$x.fossil]] |
| 21 | 24 | } |
| 22 | 25 | |
| 23 | 26 | catch {file delete $longpath/$x.fossil} |
| 24 | -catch {file delete [pwd]/$x/$x.fossil} | |
| 25 | -catch {file delete [pwd]/$x} | |
| 26 | - | |
| 27 | +catch {file delete $longpath} | |
| 28 | +catch {file delete [file dirname $longpath]} | |
| 27 | 29 |
| --- test/longpath.test | |
| +++ test/longpath.test | |
| @@ -1,10 +1,14 @@ | |
| 1 | # |
| 2 | # Tests using a repo path >512 chars. |
| 3 | # |
| 4 | # This test should pass on any platform. |
| 5 | # |
| 6 | |
| 7 | # Fossil will write data on $HOME, running 'fossil new' here. |
| 8 | # We need not to clutter the $HOME of the test caller. |
| 9 | # |
| 10 | set env(HOME) [pwd] |
| @@ -11,16 +15,14 @@ | |
| 11 | |
| 12 | # Create the repo |
| 13 | # |
| 14 | set x [string repeat x 240] |
| 15 | set longpath [pwd]/$x/$x |
| 16 | file mkdir [pwd]/$x |
| 17 | file mkdir $longpath |
| 18 | |
| 19 | test longpath-test.1 { |
| 20 | ![regexp CANTOPEN [fossil new $longpath/$x.fossil]] |
| 21 | } |
| 22 | |
| 23 | catch {file delete $longpath/$x.fossil} |
| 24 | catch {file delete [pwd]/$x/$x.fossil} |
| 25 | catch {file delete [pwd]/$x} |
| 26 | |
| 27 |
| --- test/longpath.test | |
| +++ test/longpath.test | |
| @@ -1,10 +1,14 @@ | |
| 1 | # |
| 2 | # Tests using a repo path >512 chars. |
| 3 | # |
| 4 | # This test should pass on any platform. |
| 5 | # |
| 6 | |
| 7 | if {$::tcl_platform(platform)!="unix"} { |
| 8 | exit |
| 9 | } |
| 10 | |
| 11 | # Fossil will write data on $HOME, running 'fossil new' here. |
| 12 | # We need not to clutter the $HOME of the test caller. |
| 13 | # |
| 14 | set env(HOME) [pwd] |
| @@ -11,16 +15,14 @@ | |
| 15 | |
| 16 | # Create the repo |
| 17 | # |
| 18 | set x [string repeat x 240] |
| 19 | set longpath [pwd]/$x/$x |
| 20 | file mkdir $longpath |
| 21 | |
| 22 | test longpath-test.1 { |
| 23 | ![regexp CANTOPEN [fossil new $longpath/$x.fossil]] |
| 24 | } |
| 25 | |
| 26 | catch {file delete $longpath/$x.fossil} |
| 27 | catch {file delete $longpath} |
| 28 | catch {file delete [file dirname $longpath]} |
| 29 |