added tests for code introduced in #87