@@ -45,7 +45,6 @@ def rerun_filter(exc, *args):
4545
4646
4747@pytest .mark .flaky (max_runs = 5 , min_passes = 1 , rerun_filter = rerun_filter )
48- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
4948def test_create (p : P , event_queue : TestEventQueue , start_watching : StartWatching , expect_event : ExpectEvent ) -> None :
5049 start_watching ()
5150 open (p ("a" ), "a" ).close ()
@@ -66,7 +65,6 @@ def test_create(p: P, event_queue: TestEventQueue, start_watching: StartWatching
6665
6766@pytest .mark .skipif (not platform .is_linux (), reason = "FileClosed*Event only supported in GNU/Linux" )
6867@pytest .mark .flaky (max_runs = 5 , min_passes = 1 , rerun_filter = rerun_filter )
69- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
7068def test_closed (p : P , event_queue : TestEventQueue , start_watching : StartWatching ) -> None :
7169 with open (p ("a" ), "a" ):
7270 start_watching ()
@@ -99,7 +97,6 @@ def test_closed(p: P, event_queue: TestEventQueue, start_watching: StartWatching
9997 platform .is_darwin () or platform .is_windows (),
10098 reason = "Windows and macOS enforce proper encoding" ,
10199)
102- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
103100def test_create_wrong_encoding (p : P , event_queue : TestEventQueue , start_watching : StartWatching ) -> None :
104101 start_watching ()
105102 open (p ("a_\udce4 " ), "a" ).close ()
@@ -115,7 +112,6 @@ def test_create_wrong_encoding(p: P, event_queue: TestEventQueue, start_watching
115112
116113
117114@pytest .mark .flaky (max_runs = 5 , min_passes = 1 , rerun_filter = rerun_filter )
118- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
119115def test_delete (p : P , start_watching : StartWatching , expect_event : ExpectEvent ) -> None :
120116 mkfile (p ("a" ))
121117
@@ -129,7 +125,6 @@ def test_delete(p: P, start_watching: StartWatching, expect_event: ExpectEvent)
129125
130126
131127@pytest .mark .flaky (max_runs = 5 , min_passes = 1 , rerun_filter = rerun_filter )
132- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
133128def test_modify (p : P , event_queue : TestEventQueue , start_watching : StartWatching , expect_event : ExpectEvent ) -> None :
134129 mkfile (p ("a" ))
135130 start_watching ()
@@ -150,7 +145,6 @@ def test_modify(p: P, event_queue: TestEventQueue, start_watching: StartWatching
150145
151146
152147@pytest .mark .flaky (max_runs = 5 , min_passes = 1 , rerun_filter = rerun_filter )
153- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
154148def test_chmod (p : P , start_watching : StartWatching , expect_event : ExpectEvent ) -> None :
155149 mkfile (p ("a" ))
156150 start_watching ()
@@ -166,7 +160,6 @@ def test_chmod(p: P, start_watching: StartWatching, expect_event: ExpectEvent) -
166160
167161
168162@pytest .mark .flaky (max_runs = 5 , min_passes = 1 , rerun_filter = rerun_filter )
169- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
170163def test_move (p : P , event_queue : TestEventQueue , start_watching : StartWatching , expect_event : ExpectEvent ) -> None :
171164 mkdir (p ("dir1" ))
172165 mkdir (p ("dir2" ))
@@ -196,7 +189,6 @@ def test_move(p: P, event_queue: TestEventQueue, start_watching: StartWatching,
196189
197190
198191@pytest .mark .flaky (max_runs = 5 , min_passes = 1 , rerun_filter = rerun_filter )
199- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
200192def test_case_change (
201193 p : P ,
202194 event_queue : TestEventQueue ,
@@ -231,7 +223,6 @@ def test_case_change(
231223
232224
233225@pytest .mark .flaky (max_runs = 5 , min_passes = 1 , rerun_filter = rerun_filter )
234- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
235226def test_move_to (p : P , start_watching : StartWatching , expect_event : ExpectEvent ) -> None :
236227 mkdir (p ("dir1" ))
237228 mkdir (p ("dir2" ))
@@ -247,7 +238,6 @@ def test_move_to(p: P, start_watching: StartWatching, expect_event: ExpectEvent)
247238
248239
249240@pytest .mark .skipif (not platform .is_linux (), reason = "InotifyFullEmitter only supported in Linux" )
250- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
251241def test_move_to_full (p : P , event_queue : TestEventQueue , start_watching : StartWatching ) -> None :
252242 mkdir (p ("dir1" ))
253243 mkdir (p ("dir2" ))
@@ -262,7 +252,6 @@ def test_move_to_full(p: P, event_queue: TestEventQueue, start_watching: StartWa
262252
263253
264254@pytest .mark .flaky (max_runs = 5 , min_passes = 1 , rerun_filter = rerun_filter )
265- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
266255def test_move_from (p : P , start_watching : StartWatching , expect_event : ExpectEvent ) -> None :
267256 mkdir (p ("dir1" ))
268257 mkdir (p ("dir2" ))
@@ -278,7 +267,6 @@ def test_move_from(p: P, start_watching: StartWatching, expect_event: ExpectEven
278267
279268
280269@pytest .mark .skipif (not platform .is_linux (), reason = "InotifyFullEmitter only supported in Linux" )
281- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
282270def test_move_from_full (p : P , event_queue : TestEventQueue , start_watching : StartWatching ) -> None :
283271 mkdir (p ("dir1" ))
284272 mkdir (p ("dir2" ))
@@ -293,7 +281,6 @@ def test_move_from_full(p: P, event_queue: TestEventQueue, start_watching: Start
293281
294282
295283@pytest .mark .flaky (max_runs = 5 , min_passes = 1 , rerun_filter = rerun_filter )
296- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
297284def test_separate_consecutive_moves (p : P , start_watching : StartWatching , expect_event : ExpectEvent ) -> None :
298285 mkdir (p ("dir1" ))
299286 mkfile (p ("dir1" , "a" ))
@@ -322,7 +309,6 @@ def test_separate_consecutive_moves(p: P, start_watching: StartWatching, expect_
322309
323310@pytest .mark .flaky (max_runs = 5 , min_passes = 1 , rerun_filter = rerun_filter )
324311@pytest .mark .skipif (platform .is_bsd (), reason = "BSD create another set of events for this test" )
325- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
326312def test_delete_self (p : P , start_watching : StartWatching , expect_event : ExpectEvent ) -> None :
327313 mkdir (p ("dir1" ))
328314 emitter = start_watching (path = p ("dir1" ))
@@ -336,7 +322,6 @@ def test_delete_self(p: P, start_watching: StartWatching, expect_event: ExpectEv
336322 platform .is_windows () or platform .is_bsd (),
337323 reason = "Windows|BSD create another set of events for this test" ,
338324)
339- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
340325def test_fast_subdirectory_creation_deletion (p : P , event_queue : TestEventQueue , start_watching : StartWatching ) -> None :
341326 root_dir = p ("dir1" )
342327 sub_dir = p ("dir1" , "subdir1" )
@@ -369,7 +354,6 @@ def test_fast_subdirectory_creation_deletion(p: P, event_queue: TestEventQueue,
369354
370355
371356@pytest .mark .flaky (max_runs = 5 , min_passes = 1 , rerun_filter = rerun_filter )
372- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
373357def test_passing_unicode_should_give_unicode (p : P , event_queue : TestEventQueue , start_watching : StartWatching ) -> None :
374358 start_watching (path = str (p ()))
375359 mkfile (p ("a" ))
@@ -389,7 +373,6 @@ def test_passing_bytes_should_give_bytes(p: P, event_queue: TestEventQueue, star
389373
390374
391375@pytest .mark .flaky (max_runs = 5 , min_passes = 1 , rerun_filter = rerun_filter )
392- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
393376def test_recursive_on (p : P , event_queue : TestEventQueue , start_watching : StartWatching ) -> None :
394377 mkdir (p ("dir1" , "dir2" , "dir3" ), parents = True )
395378 start_watching ()
@@ -416,7 +399,6 @@ def test_recursive_on(p: P, event_queue: TestEventQueue, start_watching: StartWa
416399
417400
418401@pytest .mark .flaky (max_runs = 5 , min_passes = 1 , rerun_filter = rerun_filter )
419- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
420402def test_recursive_off (
421403 p : P ,
422404 event_queue : TestEventQueue ,
@@ -461,7 +443,6 @@ def test_recursive_off(
461443
462444
463445@pytest .mark .flaky (max_runs = 5 , min_passes = 1 , rerun_filter = rerun_filter )
464- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
465446def test_renaming_top_level_directory (
466447 p : P ,
467448 event_queue : TestEventQueue ,
@@ -514,7 +495,6 @@ def test_renaming_top_level_directory(
514495
515496
516497@pytest .mark .skipif (platform .is_windows (), reason = "Windows create another set of events for this test" )
517- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
518498def test_move_nested_subdirectories (
519499 p : P ,
520500 event_queue : TestEventQueue ,
@@ -559,7 +539,6 @@ def test_move_nested_subdirectories(
559539 not platform .is_windows (),
560540 reason = "Non-Windows create another set of events for this test" ,
561541)
562- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
563542def test_move_nested_subdirectories_on_windows (
564543 p : P ,
565544 event_queue : TestEventQueue ,
@@ -605,7 +584,6 @@ def test_move_nested_subdirectories_on_windows(
605584
606585@pytest .mark .flaky (max_runs = 5 , min_passes = 1 , rerun_filter = rerun_filter )
607586@pytest .mark .skipif (platform .is_bsd (), reason = "BSD create another set of events for this test" )
608- @pytest .mark .thread_unsafe (reason = "Uses recwarn" )
609587def test_file_lifecyle (p : P , start_watching : StartWatching , expect_event : ExpectEvent ) -> None :
610588 start_watching ()
611589
0 commit comments