def test_queryparam_setters(): q = QueryParams({"a": 1}) q.update([]) assert str(q) == "a=1" q = QueryParams([("a", 1), ("a", 2)]) q["a"] = "3" assert str(q) == "a=3"
def test_queryparam_setters(): q = QueryParams({"a": 1}) q.update([]) assert str(q) == "a=1" q = QueryParams([("a", 1), ("a", 2)]) q["a"] = "3" assert str(q) == "a=3" q = QueryParams([("a", 1), ("b", 1)]) u = QueryParams([("b", 2), ("b", 3)]) q.update(u) assert str(q) == "a=1&b=2&b=3" assert q["b"] == u["b"]