Test handleResponse