Use http.HandlerFunc instead of string for table tests and extract tables outside of the function with relevant names