Uncover errors on existing tests regarding ADD cache and file metadata

Docker-DCO-1.1-Signed-off-by: Abel Muiño <amuino@gmail.com> (github: amuino)
Fix ADD cache issues by skipping file headers (only sum the content).

Docker-DCO-1.1-Signed-off-by: Abel Muiño <amuino@gmail.com> (github: amuino)
Reformatted source code

Docker-DCO-1.1-Signed-off-by: Abel Muiño <amuino@gmail.com> (github: amuino)