def test_concat_choices():

    choices1 = model_helpers.Choices({"X": 1, "Y": 2})
    choices2 = choices1 + model_helpers.Choices({}) * {"B": 4, "A": 5}
    # Items of each list are ordered by when concatenated they are not re-ordered
    # items of first list will appear first then items of second list
    tools.assert_equal(choices2(), [
        (1, "X"),
        (2, "Y"),
        (5, "A"),
        (4, "B")])

    # Duplicate key
    tools.assert_raises(ValueError, choices1.__add__, {"X": 7})
dataset/ETHPy150Open rewardz/django_model_helpers/tests/test_choices.py/test_concat_choices/operator `+` -> `*`