code: def test_all_static(module: ModuleType) -> None:
      module_path = get_module_path(module)
      tree = ast.parse(module_path.read_text(), str(module_path))
      assert isinstance(tree, ast.Module)
  
      def is_all_assignment(t: Any) -> bool:
          return (
              isinstance(t, ast.Assign)
              and len(t.targets) == 1
              and isinstance(t.targets[0], ast.Name)
              and t.targets[0].id == "__all__"
          )
  
      all_assignment: Optional[ast.Assign] = None
      for t in tree.body:
          if is_all_assignment(t):
              all_assignment = t  # type: ignore[assignment]
      assert (
          all_assignment is not None
      ), f"No `__all__` found in module {module}."
  
      error_message = "__all__ must be a static list of constant strings. Some tools expect this."
  
      all_value = all_assignment.value
      assert isinstance(all_value, ast.List), error_message
  
      assert all(
          # Actual type depends on Python version:
          (isinstance(t, ast.Constant) or isinstance(t, ast.Str))
          for t in all_value.elts
      ), error_message
  
file_path: GPflow/tests/gpflow/test_all.py
imports: import ast
  import importlib
  from pathlib import Path
  from types import ModuleType
  from typing import Any, List, Optional, Sequence
  import pytest
  import gpflow
label_desc: Use image node_id 7 for calling a global function with example usage: test_all_static(module) and returns: unknown