moved test to bin folder
fixes fail if no bin dir
better error handling for do_chunk
check for errors calling chunk.
fix test