code: def test_validate_should_fail_if_there_is_no_nested_field_for_union(
      self,
  ):
      specification = [
          dict(name="an_union", type="union", optional=False, fields=[])
      ]
      body = {}
  
      validator = GcpBodyFieldValidator(specification, "v1")
  
      with pytest.raises(GcpValidationSpecificationException):
          validator.validate(body)
  
imports: from __future__ import annotations
  import pytest
  from airflow.providers.google.cloud.utils.field_validator import GcpBodyFieldValidator, GcpFieldValidationException, GcpValidationSpecificationException
label_desc: Use image node_id 20 for calling the TestGcpBodyFieldValidator obj's underlying member method code with example usage: obj.test_validate_should_fail_if_there_is_no_nested_field_for_union() without return types