refactor
add helpers
remove blank lines
refactor
fix tests