Example #1
0
def test_truncate():
	K = KVFS(dict())
	K.create("/blub")
	K.write("/blub", "hello world")
	K.truncate("/blub", 5)
	data = K.read("/blub", 10)
	assert data == "hello"
Example #2
0
def test_noexists_truncate():
	K = KVFS(dict())
	K.truncate("/blub", 5)