Add unit tests for model helper