test write -> read for more inputs (failing)
fix reader EOF handling