code: def test_aggregates_widget_setattr(self):
      data = {"a": [1, 2, 3], "b": ["a", "b", "c"]}
      widget = PerspectiveWidget(data)
      widget.aggregates = {"a": Aggregate.ANY, "b": Aggregate.LAST}
      assert widget.aggregates == {"a": "any", "b": "last"}
  
file_path: perspective/python/perspective/perspective/tests/core/test_aggregates.py
imports: from pytest import raises
  from perspective import PerspectiveError, PerspectiveViewer, PerspectiveWidget, Aggregate, Table
label_desc: Use image node_id 3 for calling the TestAggregates obj's underlying member method code with example usage: obj.test_aggregates_widget_setattr() without return types