refactor processRecursive
better test names
process option handles keys as well as items