[V3 Config] Implement a true clear method (#1344)

* Add clear methods to drivers

* Update config clear methods, add to Value

* Add test
This commit is contained in:
Will
2018-02-26 01:07:28 -05:00
committed by palmtree5
parent c1ac78eea4
commit e13de0950c
5 changed files with 68 additions and 19 deletions

View File

@@ -298,6 +298,16 @@ async def test_member_clear_all(config, member_factory):
assert len(await config.all_members()) == 0
@pytest.mark.asyncio
async def test_clear_value(config_fr):
config_fr.register_global(foo=False)
await config_fr.foo.set(True)
await config_fr.foo.clear()
with pytest.raises(KeyError):
await config_fr.get_raw('foo')
# Get All testing
@pytest.mark.asyncio
async def test_user_get_all_from_kind(config, user_factory):