class_docstr: Tests whether it's possible to use Ray Tune without soft dependencies
class_docstr_tok: ["Tests","whether","it","'s","possible","to","use","Ray","Tune","without","soft","dependencies"]
code: def testSoftImports(self):
      import ray.tune.schedulers  # noqa: F401
      from ray.tune.search import SEARCH_ALG_IMPORT
  
      for name, import_func in SEARCH_ALG_IMPORT.items():
          print(f"testing searcher {name}")
          searcher = import_func()
  
          # ensure that the dependencies aren't actually installed
          if searcher and name not in ("variant_generator", "random"):
              with self.assertRaises((AssertionError, ImportError)):
                  searcher()
  
imports: import sys
  import unittest
label_desc: Use image node_id 1 for calling the TestSoftImports obj's underlying member method code with example usage: obj.testSoftImports() without return types