Fix mvn dependency not added when scope is 'test (scope not updated to compile)'

Add ERT tests to fix the problem