File tree Expand file tree Collapse file tree 2 files changed +12
-0
lines changed
src/Symfony/Component/Filesystem/Tests Expand file tree Collapse file tree 2 files changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -50,6 +50,10 @@ public function testCopyUnreadableFileFails()
50
50
$ this ->markTestSkipped ('This test cannot run on Windows. ' );
51
51
}
52
52
53
+ if (!getenv ('USER ' ) || 'root ' === getenv ('USER ' )) {
54
+ $ this ->markTestSkipped ('This test will fail if run under superuser ' );
55
+ }
56
+
53
57
$ sourceFilePath = $ this ->workspace .\DIRECTORY_SEPARATOR .'copy_source_file ' ;
54
58
$ targetFilePath = $ this ->workspace .\DIRECTORY_SEPARATOR .'copy_target_file ' ;
55
59
@@ -124,6 +128,10 @@ public function testCopyWithOverrideWithReadOnlyTargetFails()
124
128
$ this ->markTestSkipped ('This test cannot run on Windows. ' );
125
129
}
126
130
131
+ if (!getenv ('USER ' ) || 'root ' === getenv ('USER ' )) {
132
+ $ this ->markTestSkipped ('This test will fail if run under superuser ' );
133
+ }
134
+
127
135
$ sourceFilePath = $ this ->workspace .\DIRECTORY_SEPARATOR .'copy_source_file ' ;
128
136
$ targetFilePath = $ this ->workspace .\DIRECTORY_SEPARATOR .'copy_target_file ' ;
129
137
Original file line number Diff line number Diff line change @@ -49,6 +49,10 @@ public function testErrorHandlingInLockIfLockPathBecomesUnwritable()
49
49
$ this ->markTestSkipped ('This test cannot run on Windows. ' );
50
50
}
51
51
52
+ if (!getenv ('USER ' ) || 'root ' === getenv ('USER ' )) {
53
+ $ this ->markTestSkipped ('This test will fail if run under superuser ' );
54
+ }
55
+
52
56
$ lockPath = sys_get_temp_dir ().'/ ' .uniqid ('' , true );
53
57
$ e = null ;
54
58
$ wrongMessage = null ;
You can’t perform that action at this time.
0 commit comments