

def test_can_delete_values(client):
    client.get('/store-in-session/k1/value1/')
    client.get('/store-in-session/k2/value2/')
    rv = client.get('/dump-session/')
    s = json_dec(rv.data)
    assert (s['k1'] == 'value1')
    assert (s['k2'] == 'value2')
    client.get('/delete-from-session/k1/')
    rv = client.get('/dump-session/')
    s = json_dec(rv.data)
    assert ('k1' not in s)
    assert (s['k2'] == 'value2')

dataset/ETHPy150Open mbr/flask-kvsession/tests/test_flask_kvsession.py test_can_delete_values/original