code: def test_timer_interval_choice():
      Timer(duration=timedelta(), interval="step")
      Timer(duration=timedelta(), interval="epoch")
      with pytest.raises(
          MisconfigurationException, match="Unsupported parameter value"
      ):
          Timer(duration=timedelta(), interval="invalid")
  
imports: import logging
  import time
  from datetime import timedelta
  from unittest.mock import Mock, patch
  import pytest
  from lightning.pytorch import Trainer
  from lightning.pytorch.callbacks import ModelCheckpoint
  from lightning.pytorch.callbacks.timer import Timer
  from lightning.pytorch.demos.boring_classes import BoringModel
  from lightning.pytorch.utilities.exceptions import MisconfigurationException
  from tests_pytorch.helpers.runif import RunIf
label_desc: Use image node_id 3 for calling a global function with example usage: test_timer_interval_choice() without return types