tests: test convert array to entity