Added tests. Fixed bug with arrays containing simple strings