<html>
<head>
<script src="../../resources/js-test-pre.js"></script>
<script>
if (window.testRunner)
    testRunner.dumpAsText();
</script>
</head>
<body>
<script>
description("Tests Bugzilla Bug 9815: JavaScript TypeError loading Dean Edwards' JS compressor/obfuscator");

function MyClass() 
{
}

MyClass.runTest = function() 
{
    var objTest = new this.func;
    return objTest.internalFunc;
}

MyClass.func = new Function("return this");

MyClass.func.prototype = 
{
    internalFunc: function() { }
}

var actual = "" + MyClass.runTest();
shouldBe("actual", "'function() { }'");
</script>
<script src="../../resources/js-test-post.js"></script>
</body>
</html>
