ES6 __proto__ test suite
bruant.d at gmail.com
Tue Apr 23 10:34:28 PDT 2013
Based on recent messages on es-discuss, I feel that both es-discuss and
apparently even TC39 meetings with notes have left ambiguity in what
people understood the TC39 agreement was. I believe this ambiguity is
due to this pretty bad communication format called the English language
(For anyone in doubt, French is as bad; I'm afraid it's a property
inherent to natural languages :-) ).
This is wasting everyone time and energy. This generate frustration
additional to the already existing frustration caused by standardizing
__proto__ at all.
So I would like to encourage TC39 to discuss around and create consensus
around a test suite. Most people write code snippets anyway in emails.
Let's just gather them and make sure everyone agree on the test suite.
As a materialization of this encouragement, I have started a __proto__
test suite  that attempts to capture the current consensus and recent
A couple of things:
* It is CC0 licenced to allow ECMA to pull these tests, copy them, adapt
them without any issue.
* It is built with qunit . I would have loved to use the ES5 test
harness tool, but its API is unfortunately completly undocumented. I
believe qunit is clear and unambiguous enough to make a better job at
capturing the current consensus and list places where there is no
consensus. (I hope Github will play a role in that too :-) )
* To prevent (!) code reuse and enable cross-realm testing, I've
embedded tests as inline <script>
* I'll try to keep up with consensus and feedback, but I'm just one
person. Feel free to send pull requests. Why not move the discussion to
these pull requests if appropriate.
* Feel free to fork and lead the project your own way if you think the
way I do it is stupid. I won't get offended. My only goal here is for
the __proto__ discussion to get more structure than it currently has.
* For some tests, I have lost track of what's agreed on and even what
are all the alternatives, so I've left a TODO.
* I haven't run the tests in current browsers yet besides to check that
I didn't have syntax errors :-)
I encourage everyone who cares to review the current tests and send
Can someone explain or write tests regarding what's supposed to happen
for JSON, please?
More information about the es-discuss