code: def test_vat_run_raises(
      fmodel_and_data_ext_for_attacks: ModeAndDataAndDescription,
  ) -> None:
      (fmodel, x, y), _, _ = fmodel_and_data_ext_for_attacks
      if isinstance(x, ep.NumPyTensor):
          pytest.skip()
  
      with pytest.raises(ValueError, match="unsupported criterion"):
          attack = fbn.attacks.VirtualAdversarialAttack(steps=10)
          attack.run(
              fmodel, x, fbn.TargetedMisclassification(y), epsilon=1.0
          )
  
      with pytest.raises(
          ValueError, match="expected labels to have shape"
      ):
          attack = fbn.attacks.VirtualAdversarialAttack(steps=10)
          attack.run(fmodel, x, ep.concatenate((y, y), 0), epsilon=1.0)
  
file_path: foolbox/tests/test_attacks_raise.py
imports: from typing import List, Tuple, Any
  import pytest
  import eagerpy
  import foolbox
  from conftest import ModeAndDataAndDescription
label_desc: Use image node_id 8 for calling a global function with example usage: test_vat_run_raises(fmodel_and_data_ext_for_attacks) without return types