minor dry up
add some tests