I wrote something, in a way it works
allIDs = ma.getCheckAll;
res=ma.getCheckResult(allIDs);
nTest=length(res);
TestPassed=0;
NumTestPassed=0;
WarningOrError=0;
for index=1:1:nTest
    if index==12|| index==15 || index==16  || index==20
      end
      resTmp=res(index);
      if iscell(resTmp)
          resBTmp=resTmp{1,1};
          if (length(resBTmp)==2)
              stringres=char(resBTmp{1,1});
          else
              stringres=resBTmp;
          end
          if(~isempty(regexp(stringres,'Passed')))
              TestPassed=1;
              NumTestPassed=NumTestPassed+1;
          else
              WarningOrError=WarningOrError+1;
          end
      else
          TestPassed=0;
      end
  end
