fix bug in test