fixed bug in test-cases