fixing warning at t.Errorf