bug fix to tests