Bug fix in test