Added test for extract metadata encoding problem
Added mime-type and encoding for fields that are non ascii.