def test_default_imports():
 code = 'if 1:\n        import dask\n        import sys\n\n        print(sorted(sys.modules))\n        '
 out = subprocess.check_output([sys.executable, '-c', code])
 modules = set(eval(out.decode()))
 assert ('dask' in modules)
 blacklist = ['dask.array', 'dask.dataframe', 'numpy', 'pandas', 'partd', 's3fs', 'distributed']
 for mod in blacklist:
  assert (mod not in modules)

def test_default_imports ( ) : code = 'if 1:\n        import dask\n        import sys\n\n        print(sorted(sys.modules))\n        ' out = subprocess . check_output ( [ sys . executable , '-c' , code ] ) modules = set ( eval ( out . decode ( ) ) ) assert ( 'dask' in modules ) blacklist = [ 'dask.array' , 'dask.dataframe' , 'numpy' , 'pandas' , 'partd' , 's3fs' , 'distributed' ] for mod in blacklist : assert ( mod not in modules )
startup time: import dask should not import too many modules .