@@ -329,29 +329,24 @@ def update_for_pending_release():
329
329
)
330
330
331
331
332
- def has_no_effect_on_tests (path ):
333
- """Is this a file which has we can safely assume has no effect on tests ?"""
332
+ def could_affect_tests (path ):
333
+ """Does this file have any effect on test results ?"""
334
334
# RST files are the input to some tests -- in particular, the
335
335
# documentation build and doctests. Both of those jobs are always run,
336
336
# so we can ignore their effect here.
337
337
#
338
338
# IPython notebooks aren't currently used in any tests.
339
339
if path .endswith (('.rst' , '.ipynb' )):
340
- return True
340
+ return False
341
341
342
342
# These files exist but have no effect on tests.
343
343
if path in ('CITATION' , 'LICENSE.txt' , ):
344
- return True
345
-
346
- # All of these files definitely have an effect on tests, and we should
347
- # always run tests if any of them have changed.
348
- if path .startswith (('src/' , 'tests/' , 'requirements/' , 'setup.py' )):
349
344
return False
350
345
351
346
# We default to marking a file "interesting" unless we know otherwise --
352
347
# it's better to run tests that could have been skipped than skip tests
353
348
# when they needed to be run.
354
- return False
349
+ return True
355
350
356
351
357
352
def changed_files_from_master ():
@@ -393,7 +388,7 @@ def should_run_ci_task(task, is_pull_request):
393
388
changed_files = changed_files_from_master ()
394
389
395
390
interesting_changed_files = [
396
- f for f in changed_files if not has_no_effect_on_tests (f )
391
+ f for f in changed_files if could_affect_tests (f )
397
392
]
398
393
399
394
if interesting_changed_files :
0 commit comments