Test structure improvements

(this PR also includes #16 because of reasons)