added regression test for #679