optimize well testing