code: def test_validate_false():
      template = pio.templates.default
      try:
          pio.templates.default = None
  
          # Build figure with variety of invalid properties (both name and value),
          # make sure underscore notation is still applied properly
  
          fig = go.Figure(_validate=False, **build_invalid_fig())
          assert json.loads(fig.to_json()) == expected_invalid_dict
  
          with pytest.raises(ValueError):
              go.Figure(_validate=True, **build_invalid_fig())
  
      finally:
          pio.templates.default = template
  
imports: import plotly.graph_objs
  import json
  import pytest
  import plotly.io
label_desc: Use image node_id 2 for calling a global function with example usage: test_validate_false() without return types