Tighten the validation for file content integrity.

Updated tests that tested file content with a tighter regex to guarantee file data integrity.