ammend #787 test suite and other fixes