(#5274) Tests for hostprovider removes comments
I noticed that the hostprovider will remove all inline comments from the
/etc/hosts file, when puppet updates at least one entry. Puppet will also
remove comments from entries, the user doesnt want to manage with
puppet.
To split up changes a bit this commit will only introduce tests for the
host type and the hostprovider. A few will fail, indicating the bug:
The hostprovider parses all entries and builds a hash. When building
the recordhash all comments are discarded. When puppet has to update at
least one entry it uses the to_line function to convert the record hash
back to a file. Because the comments are not stored in the hash, they
cannot be written back to the file.