add new array tests and fixed array bugs