code: def test_init() -> None:
      # Test that a positive `min_n_trials` does not raise any error.
      Terminator(min_n_trials=1)
  
      with pytest.raises(ValueError):
          # Test that a non-positive `min_n_trials` raises ValueError.
          Terminator(min_n_trials=0)
  
      Terminator(BestValueStagnationEvaluator(), min_n_trials=1)
  
file_path: optuna/tests/terminator_tests/test_terminator.py
imports: from __future__ import annotations
  import pytest
  from optuna.study._study_direction import StudyDirection
  from optuna.study.study import create_study
  from optuna.terminator import BaseImprovementEvaluator
  from optuna.terminator import StaticErrorEvaluator
  from optuna.terminator import Terminator
  from optuna.terminator.improvement.evaluator import BestValueStagnationEvaluator
  from optuna.trial import FrozenTrial
label_desc: Use image node_id 1 for calling a global function with example usage: test_init() without return types