title: Golang: Compare XML structures
body: <p>I need to write a test to verify server response. Response must contain certain headers and xml body.
  First, How can I check that the required headers are present in the response.
   And how can I compare received XML and required XML.</p>
  
  <p>For example. Response must contain header "Serv". And body must me contain xml with object "person"</p>
  
  <pre><code>HTTP/1.1 200 OK
  Connection: Keep-Alive
  Serv: "any-string"
  Content-Length: 0
  Content-Type: text/xml; charset=UTF-8
  &lt;?xml version="1.0" encoding="utf-8"?&gt;
  
  &lt;person&gt;
    &lt;name&gt;string-value&lt;/name&gt;
  &lt;/person&gt;
  </code></pre>
  
  <p>How can I check that response contain header "Serv" and contain body xml with element person and name</p>