add some unit tests for #29