Added Sonar JUnit XML format change

Hi,
We made some changes in index.js, sonarqube will not display all failures so we made some changes in xml preparation without effecting existing one.
Changed junit xml format preparation to the following way,

< testcase >
< error / >
< /testcase >
< testcase >
< failure />
< /testcase > 
instead of 
< testcase >
< failure />
< failure />
< error />
< /testcase >

Kindly update this changes, it may useful for sonarqube users.