Add encrypted document tests
Add method to get charset