class_docstr: Test ability to marshall arrow_vega_lite_chart protos.
class_docstr_tok: ["Test","ability","to","marshall","arrow_vega_lite_chart","protos","."]
docstr: Test passing datasets={foo: df}, data={name: 'foo'} in the spec.
docstr_tok: ["Test","passing","datasets=","{","foo",":","df","}",",","data=","{","name",":","'foo","'","}","in","the","spec","."]
code: def test_datasets_correctly_in_spec(self):
      """Test passing datasets={foo: df}, data={name: 'foo'} in the spec."""
      st.vega_lite_chart(
          {
              "mark": "rect",
              "datasets": {"foo": df1},
              "data": {"name": "foo"},
          }
      )
  
      proto = (
          self.get_delta_from_queue().new_element.arrow_vega_lite_chart
      )
      self.assertEqual(proto.HasField("data"), False)
      self.assertDictEqual(
          json.loads(proto.spec),
          merge_dicts(
              autosize_spec, {"data": {"name": "foo"}, "mark": "rect"}
          ),
      )
  
imports: import json
  import pandas
  import pyarrow
  from parameterized import parameterized
  import streamlit
  from streamlit.errors import StreamlitAPIException
  from streamlit.type_util import bytes_to_data_frame, pyarrow_table_to_bytes
  from tests.delta_generator_test_case import DeltaGeneratorTestCase
label_desc: Use image node_id 8 for calling the ArrowVegaLiteTest obj's underlying member method code with example usage: obj.test_datasets_correctly_in_spec() without return types