예제 #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"
예제 #2
0
def test_noexists_truncate():
	K = KVFS(dict())
	K.truncate("/blub", 5)