# Path: raccoon/utils.py
# def assert_series_equal(left, right, data_function=None, data_args=None):
#     """
#     For unit testing equality of two Series.
# 
#     :param left: first Series
#     :param right: second Series
#     :param data_function: if provided will use this function to assert compare the df.data
#     :param data_args: arguments to pass to the data_function
#     :return: nothing
#     """
#     assert type(left) == type(right)
#     if data_function:
#         data_args = {} if not data_args else data_args
#         data_function(left.data, right.data, **data_args)
#     else:
#         assert left.data == right.data
#     assert left.index == right.index
#     assert left.data_name == right.data_name
#     assert left.index_name == right.index_name
#     assert left.sort == right.sort
#     if isinstance(left, rc.ViewSeries):
#         assert left.offset == right.offset
#     if isinstance(left, rc.Series):
#         assert left.dropin == right.dropin


import pytest
import raccoon as rc
from raccoon.utils import assert_series_equal
    actual = rc.Series([1, 2, 3], index=[10, 11, 12], sort=True)

    # by index value
    actual.set(indexes=[12, 11, 10], values=[66, 55, 44])
    assert actual.data == [44, 55, 66]

    actual.set(indexes=[12, 10], values=[33, 11])
    assert actual.data == [11, 55, 33]

    # new rows at end
    actual.set(indexes=[12, 14, 15], values=[120, 130, 140])
    assert actual.data == [11, 55, 120, 130, 140]
    assert actual.index == [10, 11, 12, 14, 15]

    # new rows at beginning
    actual.set(indexes=[10, 4, 5], values=[-140, -120, -130])
    assert actual.data == [-120, -130, -140, 55, 120, 130, 140]
    assert actual.index == [4, 5, 10, 11, 12, 14, 15]

    # new rows in middle
    actual.set(indexes=[13, 6], values=[3131, 6060])
    assert actual.data == [-120, -130, 6060, -140, 55, 120, 3131, 130, 140]
    assert actual.index == [4, 5, 6, 10, 11, 12, 13, 14, 15]

    # new row new columns
    actual.set(indexes=[14, 15, 16], values=['zoo', 'boo', 'hoo'])
    assert actual.index == [4, 5, 6, 10, 11, 12, 13, 14, 15, 16]
    assert actual.data == [-120, -130, 6060, -140, 55, 120, 3131, 'zoo', 'boo', 'hoo']

    # values list shorter than indexes, raise error

# Path: raccoon/utils.py
# def assert_series_equal(left, right, data_function=None, data_args=None):
#     """
#     For unit testing equality of two Series.
# 
#     :param left: first Series
#     :param right: second Series
#     :param data_function: if provided will use this function to assert compare the df.data
#     :param data_args: arguments to pass to the data_function
#     :return: nothing
#     """
#     assert type(left) == type(right)
#     if data_function:
#         data_args = {} if not data_args else data_args
#         data_function(left.data, right.data, **data_args)
#     else:
#         assert left.data == right.data
#     assert left.index == right.index
#     assert left.data_name == right.data_name
#     assert left.index_name == right.index_name
#     assert left.sort == right.sort
#     if isinstance(left, rc.ViewSeries):
#         assert left.offset == right.offset
#     if isinstance(left, rc.Series):
#         assert left.dropin == right.dropin


# Path: tests/test_series/test_set.py
import pytest
import raccoon as rc
from raccoon.utils import assert_series_equal

    actual = rc.Series([1, 2, 3], index=[10, 11, 12], sort=True)

    # by index value
    actual.set(indexes=[12, 11, 10], values=[66, 55, 44])
    assert actual.data == [44, 55, 66]

    actual.set(indexes=[12, 10], values=[33, 11])
    assert actual.data == [11, 55, 33]

    # new rows at end
    actual.set(indexes=[12, 14, 15], values=[120, 130, 140])
    assert actual.data == [11, 55, 120, 130, 140]
    assert actual.index == [10, 11, 12, 14, 15]

    # new rows at beginning
    actual.set(indexes=[10, 4, 5], values=[-140, -120, -130])
    assert actual.data == [-120, -130, -140, 55, 120, 130, 140]
    assert actual.index == [4, 5, 10, 11, 12, 14, 15]

    # new rows in middle
    actual.set(indexes=[13, 6], values=[3131, 6060])
    assert actual.data == [-120, -130, 6060, -140, 55, 120, 3131, 130, 140]
    assert actual.index == [4, 5, 6, 10, 11, 12, 13, 14, 15]

    # new row new columns
    actual.set(indexes=[14, 15, 16], values=['zoo', 'boo', 'hoo'])
    assert actual.index == [4, 5, 6, 10, 11, 12, 13, 14, 15, 16]
    assert actual.data == [-120, -130, 6060, -140, 55, 120, 3131, 'zoo', 'boo', 'hoo']

    # values list shorter than indexes, raise error

    with pytest.raises(ValueError):