Update resource injection; add dimen support and update test cases