File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed
Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -5282,17 +5282,20 @@ def test_drop_all_epochs():
52825282 info = create_info (["ch1" ], 1000.0 , "eeg" )
52835283 epochs = EpochsArray (data , info )
52845284
5285- # 1. Test 'warn' (default)
5285+ # 1. Test 'ignore' (default)
5286+ epochs .copy ().drop ([0 ])
5287+
5288+ # 2. Test 'warn' explicitly
52865289 # We expect a warning when dropping all epochs
52875290 with pytest .warns (RuntimeWarning , match = "All epochs dropped" ):
5288- epochs .copy ().drop ([0 ])
5291+ epochs .copy ().drop ([0 ], on_drop_all = "warn" )
52895292
5290- # 2 . Test 'raise'
5293+ # 3 . Test 'raise'
52915294 # We expect a ValueError when dropping all epochs
52925295 with pytest .raises (ValueError , match = "All epochs dropped" ):
52935296 epochs .copy ().drop ([0 ], on_drop_all = "raise" )
52945297
5295- # 3 . Test 'ignore'
5298+ # 4 . Test 'ignore' explicitly
52965299 # Should run silently (no warning, no error)
52975300 epochs .copy ().drop ([0 ], on_drop_all = "ignore" )
52985301
You can’t perform that action at this time.
0 commit comments