code: def test_fstring_with_vars_mismatch():
      fstring = FString(template="Hello {name}", variables=["name"])
      with pytest.raises(KeyError):
          fstring.run(template="Goodbye {person}!", name="Alice")
  
imports: import pytest
  from haystack.testing.sample_components import FString
label_desc: Use image node_id 4 for calling a global function with example usage: test_fstring_with_vars_mismatch() without return types