finish Read Write and ReadAll, plus some test