예제 #1
0
def test_reducer_immutable_state():
    state = {"colorbar": {"number": 1}}
    colors.reducer(state, colors.set_palette_number(3))
    assert state["colorbar"]["number"] == 1
예제 #2
0
def test_reducer(state, action, expect):
    result = colors.reducer(state, action)
    assert expect == result