<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 14 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
span.EmailStyle17
{mso-style-type:personal;
font-family:"Calibri","sans-serif";
color:windowtext;}
span.EmailStyle18
{mso-style-type:personal-reply;
font-family:"Calibri","sans-serif";
color:#1F497D;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;}
@page WordSection1
{size:8.5in 11.0in;
margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span style="color:#1F497D">Hi everyone, yesterday a new set of improvements were uploaded to
<a href="http://test262.ecmascript.org">http://test262.ecmascript.org</a>. These included 36 test case additions which were predominantly strict mode related. We also had a couple dozen minor changes (e.g., cleanup) to existing test files.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">For browser implementers, there were a few significant changes to note. First and foremost, a lot of effort went into refactoring the test harness, sth.js, to better support running test262 against command-line
JavaScript executables in the future. For example, all code needed to detect failures of so-called “globally scoped tests” has been extracted from sth.js to gs.js, and similar refactorings occurred for other sth.js functionality. We’re not quite there yet,
but soon we should have a tool capable of generating stand-alone test files incorporating gs.js, sta.js, etc.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">If you’re an implementer preferring to run test262 directly from the browser instead of the command-line, we’ve now provided the capability of hooking your
<b>own</b> test failure reporting/passing automation into test262. In short, all you need to do is overwrite controller.implementerHook from default.html
<b>after</b> loading the test262 harness scripts with an object like this:<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="color:#1F497D">controller.implementerHook = {<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="color:#1F497D"> addTestResult: function (test) {<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="color:#1F497D"> //’test’ is the same object the test262 harness uses internally: test.path/test.description/test.result/etc. all exist<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="color:#1F497D"> if (test.result!=="pass") {<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="color:#1F497D"> alert(test.path + “: ” + test.error); //DO YOUR OWN CLEVER THING HERE<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="color:#1F497D"> }<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="color:#1F497D"> },<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="color:#1F497D"> finished: function(elapsed) {<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="color:#1F497D"> alert(“FINISHED!”);<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="color:#1F497D"> }<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="color:#1F497D">};<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">On a related note, <i>test/harness/TestCaseHTMLPackager/TestCasePackager.py</i> has a new feature in which an HTML test template taken from
<i>test/harness/TestCaseHTMLPackager/templates/*</i> can be used to generate a different default.html. As you can imagine, this feature supports ‘implementerHook’ quite nicely.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">I’ll be adding the details of these additions to the test262 Wiki shortly. If other browser implementers are interested in using this new functionality as well, I’d love to hear your thoughts on the existing
design and possible refactorings that would help make test262 even more useful in your day-to-day testing of ECMAScript.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Last but definitely not least, I encourage everyone to run the updated test suite against your favorite web browser to help identify any issues with the tests, harness, or website itself. Any issues detected
can be reported at <a href="http://bugs.ecmascript.org">http://bugs.ecmascript.org</a>. Again, thanks for everyone’s help in making test262 great!<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">My best,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Dave<o:p></o:p></span></p>
<p class="MsoNormal"><o:p></o:p></p>
</div>
</body>
</html>