code: def test_execution_engine_config():
      assert isinstance(
          ExecutionEngineConfig(name="ts"), TrainingServiceEngineConfig
      )
      assert isinstance(
          ExecutionEngineConfig(name="sequential"),
          SequentialEngineConfig,
      )
      assert TrainingServiceEngineConfig().json() == dict(name="ts")
      assert (
          ExecutionEngineConfig(
              name="sequential",
              continue_on_failure=True,
              max_duration=1,
          ).max_duration
          == 1
      )
      assert (
          ExecutionEngineConfig(
              name="cgo", max_concurrency_cgo=1, batch_waiting_time=1
          ).batch_waiting_time
          == 1
      )
  
      with pytest.raises(
          ValueError, match="Invalid ExecutionEngineConfig subclass"
      ):
          ExecutionEngineConfig(name="wrong")
      assert isinstance(ExecutionEngineConfig(), ExecutionEngineConfig)
  
imports: import pytest
  from nni.experiment.config import *
  from nni.nas.experiment.config import *
label_desc: Use image node_id 1 for calling a global function with example usage: test_execution_engine_config() without return types