var result = "REFTEST "; 
function DocumentLoaded(){    var key = IFrameToKey();    switch (gState) {        case 1:            gPart1Key = key;            StartCurrentURI(2);            break;        case 2:            var equal = (key == gPart1Key);            var result = "REFTEST ";            var test_passed = (equal == gURLs[0].equal);            var expected = gURLs[0].expected;            switch (expected) {                case EXPECTED_PASS:                    if (!test_passed) result += "UNEXPECTED ";                    break;                case EXPECTED_FAIL:                    if (test_passed) result += "UNEXPECTED ";                    break;                case EXPECTED_RANDOM:                    result += "(RESULT EXPECTED TO BE RANDOM) "                    break;            }            if (test_passed) {                result += "PASS: ";            } else {                result += "FAIL: ";            }            if (!gURLs[0].equal) {                result += "(!=) ";            }            result += gURLs[0].url1.spec;            dump(result + "\n");            if (!test_passed && expected == EXPECTED_PASS) {                dump("REFTEST   IMAGE 1 (TEST): " + gPart1Key + "\n");                dump("REFTEST   IMAGE 2 (REFERENCE): " + key + "\n");            }            gPart1Key = undefined;            gURLs.shift();            StartCurrentTest();            break;        default:            throw "Unexpected state."    }}
5459	/local1/tlutelli/issta_data/temp/all_js/javascript/2007_temp/2007/5459/2dae1140d81ddd4f1633fd6ae2f2b2ffd31232bd/reftest.js/buggy/layout/tools/reftest/reftest.js