[HttpFoundation] add test to ensure that Content-Length is preserved on HEAD method
merged branch Inori/patch-3 (PR #8876)

This PR was merged into the master branch.

Discussion
----------

[HttpFoundation] add test to ensure Content-Length is preserved on HEAD

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Related to #8873

Commits
-------

42f0596 [HttpFoundation] add test to ensure that Content-Length is preserved on HEAD method