Adding tests for element/mesh getters.
Fixing bugs found by tests.

Change-Id: I6592a3b65f16b21255e7788fe8ee8aaafe268638
8 files changed