new test (fails on trunk!), and fix for bug