229cbf
#!/usr/bin/bash
229cbf
# Analyze and print specialized (basic/webrender) test results
229cbf
229cbf
TEST_DIR=$1
229cbf
TEST_FLAVOUR=$2
229cbf
229cbf
MPASS=`grep "TEST_END: Test OK" $TEST_DIR/mochitest$TEST_FLAVOUR | wc -l`
229cbf
MERR=`grep "TEST_END: Test ERROR" $TEST_DIR/mochitest$TEST_FLAVOUR | wc -l`
229cbf
MUNEX=`grep "TEST-UNEXPECTED-FAIL" $TEST_DIR/mochitest$TEST_FLAVOUR | wc  -l`
229cbf
echo "Mochitest   PASSED: $MPASS FAILED: $MERR UNEXPECTED-FAILURES: $MUNEX"
229cbf
229cbf
XPCPASS=`grep --text "Expected results:" $TEST_DIR/xpcshell$TEST_FLAVOUR | cut -d ' ' -f 3`
229cbf
XPCFAIL=`grep --text "Unexpected results:" $TEST_DIR/xpcshell$TEST_FLAVOUR | cut -d ' ' -f 3`
229cbf
echo "XPCShell:   PASSED: $XPCPASS FAILED: $XPCFAIL"
229cbf
229cbf
CRPASS=`grep "REFTEST INFO | Successful:" $TEST_DIR/crashtest$TEST_FLAVOUR | cut -d ' ' -f 5`
229cbf
CRFAIL=`grep "^REFTEST INFO | Unexpected:" $TEST_DIR/crashtest$TEST_FLAVOUR | cut -d ' ' -f 5`
229cbf
echo "Crashtest:  PASSED: $CRPASS FAILED: $CRFAIL"
229cbf
229cbf
RFPASS=`grep --text "REFTEST INFO | Successful:" $TEST_DIR/reftest$TEST_FLAVOUR | cut -d ' ' -f 5`
229cbf
RFUN=`grep --text "^REFTEST INFO | Unexpected:" $TEST_DIR/reftest$TEST_FLAVOUR | cut -d ' ' -f 5`
229cbf
RFKNOWN=`grep --text "REFTEST INFO | Known problems:" $TEST_DIR/reftest$TEST_FLAVOUR | cut -d ' ' -f 6`
229cbf
echo "Reftest:    PASSED: $RFPASS FAILED: $RFUN Known issues: $RFKNOWN"