aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorDavid Fugate <dfugate@microsoft.com>2011-09-25 11:47:50 -0700
committerDavid Fugate <dfugate@microsoft.com>2011-09-25 11:47:50 -0700
commit5e0a22f4204b764663047b335076cbddda9f6062 (patch)
tree35b85d6c6101f1bc43c620de8cb2d87c508d14f4 /tools
parent5534d810e87360add6d32334bb66951f62bf6249 (diff)
Removed TestCaseHTMLPackager. Replacement is tools/packaging/*.
Diffstat (limited to 'tools')
-rw-r--r--tools/TestCaseHTMLPackager/TestCasePackager.py308
-rw-r--r--tools/TestCaseHTMLPackager/TestCasePackagerConfig.py110
-rw-r--r--tools/TestCaseHTMLPackager/TestUpdater.ps1bin3428 -> 0 bytes
-rw-r--r--tools/TestCaseHTMLPackager/templates/runner.test262.html170
4 files changed, 0 insertions, 588 deletions
diff --git a/tools/TestCaseHTMLPackager/TestCasePackager.py b/tools/TestCaseHTMLPackager/TestCasePackager.py
deleted file mode 100644
index 7c7a02d14..000000000
--- a/tools/TestCaseHTMLPackager/TestCasePackager.py
+++ /dev/null
@@ -1,308 +0,0 @@
-# Copyright (c) 2009 Microsoft Corporation
-#
-# Redistribution and use in source and binary forms, with or without modification, are permitted provided
-# that the following conditions are met:
-# * Redistributions of source code must retain the above copyright notice, this list of conditions and
-# the following disclaimer.
-# * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
-# the following disclaimer in the documentation and/or other materials provided with the distribution.
-# * Neither the name of Microsoft nor the names of its contributors may be used to
-# endorse or promote products derived from this software without specific prior written permission.
-#
-# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
-# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
-# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
-# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
-# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
-# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-#--Imports---------------------------------------------------------------------
-import argparse
-import os
-import sys
-import xml.dom.minidom
-import base64
-import datetime
-import shutil
-import re
-import json
-import stat
-
-#--Stubs-----------------------------------------------------------------------
-def generateHarness(harnessType, jsonFile, description):
- pass
-
-
-#------------------------------------------------------------------------------
-from TestCasePackagerConfig import *
-
-#--Globals---------------------------------------------------------------------
-
-__parser = argparse.ArgumentParser(description='Tool used to generate the test262 website')
-__parser.add_argument('version', action='store',
- help='Version of the test suite.')
-__parser.add_argument('--type', action='store', default='test262',
- help='Type of test case runner to generate.')
-ARGS = __parser.parse_args()
-
-if not os.path.exists(EXCLUDED_FILENAME):
- print "Cannot generate (JSON) test262 tests without a file, %s, showing which tests have been disabled!" % EXCLUDED_FILENAME
- sys.exit(1)
-EXCLUDE_LIST = xml.dom.minidom.parse(EXCLUDED_FILENAME)
-EXCLUDE_LIST = EXCLUDE_LIST.getElementsByTagName("test")
-EXCLUDE_LIST = [x.getAttribute("id") for x in EXCLUDE_LIST]
-
-#a list of all ES5 test chapter directories
-TEST_SUITE_SECTIONS = []
-
-#total number of tests accross the entire set of tests.
-TOTAL_TEST_COUNT = 0
-
-#global which states whether the test case we're currently processing is in
-#the midst of a "/* ... */" style comment
-IS_MULTILINE_COMMENT = False
-
-#List of all *.json files containing encoded test cases
-SECTIONS_LIST = []
-
-ONE_JSON_PER_CHAPTER = False
-TESTCASELIST_PER_JSON = False
-
-#--Sanity checks--------------------------------------------------------------#
-if not os.path.exists(TEST262_CASES_DIR):
- print "Cannot generate (JSON) test262 tests when the path containing said tests, %s, does not exist!" % TEST262_CASES_DIR
- sys.exit(1)
-
-if not os.path.exists(TEST262_HARNESS_DIR):
- print "Cannot copy the test harness from a path, %s, that does not exist!" % TEST262_HARNESS_DIR
- sys.exit(1)
-
-if not os.path.exists(TEST262_WEB_CASES_DIR):
- os.mkdir(TEST262_WEB_CASES_DIR)
-
-if not os.path.exists(TEST262_WEB_HARNESS_DIR):
- os.mkdir(TEST262_WEB_HARNESS_DIR)
-
-if not hasattr(ARGS, "version"):
- print "A test262 suite version must be specified from the command-line to run this script!"
- sys.exit(1)
-
-#--Helpers--------------------------------------------------------------------#
-def getJSCount(dirName):
- '''
- Returns the total number of *.js files (recursively) under a given
- directory, dirName.
- '''
- retVal = 0
- if os.path.isfile(dirName) and dirName.endswith(".js"):
- retVal = 1
- elif os.path.isdir(dirName):
- tempList = [os.path.join(dirName, x) for x in os.listdir(dirName)]
- for x in tempList:
- retVal += getJSCount(x)
- #else:
- # raise Exception("getJSCount: encountered a non-file/non-dir!")
- return retVal
-
-#------------------------------------------------------------------------------
-def dirWalker(dirName):
- '''
- Populates TEST_SUITE_SECTIONS with ES5 test directories based
- upon the number of test files per directory.
- '''
- global TEST_SUITE_SECTIONS
- #First check to see if it has test files directly inside it
- temp = [os.path.join(dirName, x) for x in os.listdir(dirName) if not os.path.isdir(os.path.join(dirName, x))]
- if len(temp)!=0:
- TEST_SUITE_SECTIONS.append(dirName)
- return
-
- #Next check to see if all *.js files under this directory exceed our max
- #for a JSON file
- temp = getJSCount(dirName)
- if temp==0:
- print "ERROR: expected there to be JavaScript tests under dirName!"
- sys.exit(1)
- elif temp < MAX_CASES_PER_JSON:
- TEST_SUITE_SECTIONS.append(dirName)
- return
- else:
- #Max has been exceeded. We need to look at each subdir individually
- temp = os.listdir(dirName)
- for tempSubdir in temp:
- dirWalker(os.path.join(dirName, tempSubdir))
-
-#------------------------------------------------------------------------------
-def isTestStarted(line):
- '''
- Used to detect if we've gone past extraneous test comments in a test case.
-
- Note this is a naive approach on the sense that "/*abc*/" could be on one
- line. However, we know for a fact this is not the case in IE Test Center
- or Sputnik tests.
- '''
- global IS_MULTILINE_COMMENT
-
- if IS_MULTILINE_COMMENT and ("*/" in line): #End of a newline comment
- IS_MULTILINE_COMMENT = False
- return False
- elif "/*" in line: #Beginning of a newline comment
- IS_MULTILINE_COMMENT = True
- return False
- elif IS_MULTILINE_COMMENT: #//we're already in a multi-line comment that hasn't ended
- return False
- elif re.match("^\s*//", line)!=None: #//blah
- return False
- elif re.match("^\s*$", line)!=None: #newlines
- return False
- elif "ES5Harness" in line: #definitely start of the test!
- return True
- return True
-
-#------------------------------------------------------------------------------
-def getAllJSFiles(dirName):
- retVal = []
- for fullPath,dontCare,files in os.walk(dirName):
- retVal += [os.path.join(fullPath,b) for b in files if b.endswith(".js")]
- return retVal
-
-#--MAIN------------------------------------------------------------------------
-for temp in TEST_CONTRIB_DIRS:
- temp = os.path.join(TEST262_CASES_DIR, temp)
- if not os.path.exists(temp):
- print "The expected ES5 test directory,", temp, "did not exist!"
- sys.exit(1)
-
- if not ONE_JSON_PER_CHAPTER:
- dirWalker(temp)
- else:
- for tempSubdir in os.listdir(temp):
- TEST_SUITE_SECTIONS.append(os.path.join(temp, tempSubdir))
-
-
-for chapter in TEST_SUITE_SECTIONS:
- chapterName = chapter.rsplit(os.path.sep, 1)[1]
- print "Generating test cases for ES5 chapter:", chapterName
- #create dictionaries for all our tests and a section
- testsList = {}
- sect = {}
- sect["name"] = "Chapter - " + chapterName
-
- #create an array for tests in a chapter
- tests = []
- sourceFiles = getAllJSFiles(chapter)
-
- if len(sourceFiles)!=0:
- excluded = 0
- testCount = 0
- for test in sourceFiles:
- #TODO - use something other than the hard-coded 'TestCases' below
- testPath = "TestCases" + test.split(TEST262_CASES_DIR, 1)[1].replace("\\", "/")
- testName=test.rsplit(".", 1)[0]
- testName=testName.rsplit(os.path.sep, 1)[1]
- if EXCLUDE_LIST.count(testName)==0:
- # dictionary for each test
- testDict = {}
- testDict["id"] = testName
- testDict["path"] = testPath.replace("/ietestcenter", "").replace("/sputnik_converted", "")
-
- tempFile = open(test, "r")
- scriptCode = tempFile.readlines()
- tempFile.close()
- scriptCodeContent=""
- #Rip out license headers that add unnecessary bytes to the JSON'ized test cases
- inBeginning = True
- IS_MULTILINE_COMMENT = False
-
- for line in scriptCode:
- if inBeginning:
- isStarted = isTestStarted(line)
- if not isStarted:
- continue
- inBeginning = False
- scriptCodeContent += line
-
- if scriptCodeContent=="":
- print "WARNING (" + test + "): unable to strip comments/license header/etc."
- scriptCodeContent = "".join(scriptCode)
- scriptCodeContent = base64.b64encode(scriptCodeContent)
-
- #add the test encoded code node to our test dictionary
- testDict["code"] = scriptCodeContent
- #now close the dictionary for the test
-
- #this adds the test to our tests array
- tests.append(testDict)
- testCount += 1
- else:
- print "Excluded:", testName
- excluded = excluded + 1
-
- #we have completed our tests
- # add section node, number of tests and the tests themselves.
- sect["numTests"] = str(len(sourceFiles)-excluded)
- sect["tests"] = tests
-
- #create a node for the tests and add it to our testsLists
- testsList["testsCollection"] = sect
- with open(os.path.join(TEST262_WEB_CASES_DIR, chapterName + ".json"), "w") as f:
- json.dump(testsList, f, separators=(',',':'), sort_keys=True)
-
-
- if TESTCASELIST_PER_JSON:
- CHAPTER_TEST_CASES_JSON = {}
- CHAPTER_TEST_CASES_JSON["numTests"] = int(sect["numTests"])
- CHAPTER_TEST_CASES_JSON["version"] = ARGS.version
- CHAPTER_TEST_CASES_JSON["date"] = str(datetime.datetime.now().date())
- CHAPTER_TEST_CASES_JSON["testSuite"] = [WEBSITE_CASES_PATH + chapterName + ".json"]
- with open(os.path.join(TEST262_WEB_CASES_DIR, "testcases_%s.json" % chapterName), "w") as f:
- json.dump(CHAPTER_TEST_CASES_JSON, f, separators=(',',':'), sort_keys=True)
- generateHarness(ARGS.type, "testcases_%s.json" % chapterName, chapterName.replace("chapter", "Chapter "))
-
- #add the name of the chapter test to our complete list
- SECTIONS_LIST.append(WEBSITE_CASES_PATH + chapterName + ".json")
- TOTAL_TEST_COUNT += int(sect["numTests"])
-
-
-#we now have the list of files for each chapter
-#create a root node for our suite
-TEST_CASES_JSON = {}
-TEST_CASES_JSON["numTests"] = TOTAL_TEST_COUNT
-TEST_CASES_JSON["version"] = ARGS.version
-TEST_CASES_JSON["date"] = str(datetime.datetime.now().date())
-TEST_CASES_JSON["testSuite"] = SECTIONS_LIST
-with open(os.path.join(TEST262_WEB_CASES_DIR, "default.json"), "w") as f:
- json.dump(TEST_CASES_JSON, f, separators=(',',':'), sort_keys=True)
-generateHarness(ARGS.type, "default.json", "Chapters 1-16")
-
-#Deploy test harness to website as well
-print ""
-print "Deploying test harness files to 'TEST262_WEB_HARNESS_DIR'..."
-if TEST262_HARNESS_DIR!=TEST262_WEB_HARNESS_DIR:
- for filename in [x for x in os.listdir(TEST262_HARNESS_DIR) if x.endswith(".js")]:
- toFilename = os.path.join(TEST262_WEB_HARNESS_DIR, filename)
- fileExists = os.path.exists(toFilename)
- if fileExists:
- SC_HELPER.edit(toFilename)
- shutil.copy(os.path.join(TEST262_HARNESS_DIR, filename),
- toFilename)
- if not fileExists:
- SC_HELPER.add(toFilename)
-
-#Copying the global scope files over as well
-#TODO: really the HTML harness file should be generated as well...
-print ""
-print "Deploying global scope metadata files to 'TEST262_WEB_HARNESS_DIR'..."
-for gsf in GLOBAL_SCOPE_FILES:
- toFilename = os.path.join(TEST262_WEB_CASES_DIR, gsf)
- fileExists = os.path.exists(toFilename)
- if fileExists:
- SC_HELPER.edit(toFilename)
- shutil.copy(os.path.join(TEST262_CASES_DIR, gsf),
- toFilename)
- if not fileExists:
- SC_HELPER.add(toFilename)
-
-print "Done."
diff --git a/tools/TestCaseHTMLPackager/TestCasePackagerConfig.py b/tools/TestCaseHTMLPackager/TestCasePackagerConfig.py
deleted file mode 100644
index 9364556d7..000000000
--- a/tools/TestCaseHTMLPackager/TestCasePackagerConfig.py
+++ /dev/null
@@ -1,110 +0,0 @@
-# Copyright (c) 2009 Microsoft Corporation
-#
-# Redistribution and use in source and binary forms, with or without modification, are permitted provided
-# that the following conditions are met:
-# * Redistributions of source code must retain the above copyright notice, this list of conditions and
-# the following disclaimer.
-# * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and
-# the following disclaimer in the documentation and/or other materials provided with the distribution.
-# * Neither the name of Microsoft nor the names of its contributors may be used to
-# endorse or promote products derived from this software without specific prior written permission.
-#
-# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
-# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
-# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
-# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
-# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
-# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-#--Imports---------------------------------------------------------------------
-import os
-import subprocess
-import stat
-
-#--Globals---------------------------------------------------------------------
-MAX_CASES_PER_JSON = 1000
-
-#Directories under "test\suite\" containing ES5 test chapter directories
-#with *.js tests underneath them
-TEST_CONTRIB_DIRS = ["sputnik_converted", "ietestcenter"]
-
-#Global scope source files found directly under "test\suite\".
-GLOBAL_SCOPE_FILES = ["SputnikGlobalScope.js", "IETCGlobalScope.js"]
-
-#Path to the root of the Hg repository (relative to this file's location)
-TEST262_ROOT = os.path.join(os.path.dirname(os.path.realpath(__file__)), "..", "..")
-TEST262_ROOT = os.path.abspath(TEST262_ROOT)
-
-#Directory full of test cases we want to port to the website's test harness runner
-TEST262_CASES_DIR = os.path.join(TEST262_ROOT, "test", "suite")
-
-#Directory containing test harness files to be ported over to the website. Note that
-#only *.js files will be migrated from this dir.
-TEST262_HARNESS_DIR = os.path.join(TEST262_ROOT, "test", "harness")
-
-#Directory full of website test cases (ported over from TEST262_CASES_DIR)
-TEST262_WEB_CASES_DIR = os.path.join(TEST262_ROOT, "website", "resources", "scripts", "testcases")
-
-#Directory containing the website's test harness (ported over from TEST262_HARNESS_DIR)
-TEST262_WEB_HARNESS_DIR = os.path.join(TEST262_ROOT, "website", "resources", "scripts", "global")
-
-#Path to the ported test case files on the actual website as opposed to the Hg layout
-WEBSITE_CASES_PATH = "resources/scripts/testcases/"
-
-#The name of a file which contains a list of tests which should be disabled in test262.
-#These tests are either invalid as-per ES5 or have issues with the test262 web harness.
-EXCLUDED_FILENAME = os.path.join(TEST262_ROOT, "test", "config", "excludelist.xml")
-
-#------------------------------------------------------------------------------
-
-TEMPLATE_LINES = None
-__lastHarnessType = None
-
-def generateHarness(harnessType, jsonName, title):
- global TEMPLATE_LINES
- global __lastHarnessType
- if TEMPLATE_LINES==None or harnessType!=__lastHarnessType:
- __lastHarnessType = harnessType
- TEMPLATE_LINES = []
- with open(os.path.join(os.getcwd(), "templates","runner." + harnessType + ".html"), "r") as f:
- TEMPLATE_LINES = f.readlines()
- fileName = os.path.join(TEST262_ROOT, "website", jsonName.replace(".json", ".html"))
- fileNameExists = False
- if os.path.exists(fileName):
- SC_HELPER.edit(fileName)
- fileNameExists = True
- with open(fileName, "w") as f:
- for line in TEMPLATE_LINES:
- if "var TEST_LIST_PATH =" in line:
- f.write(" var TEST_LIST_PATH = \"resources/scripts/testcases/" + jsonName + "\";" + os.linesep)
- #elif "ECMAScript 5" in line:
- # f.write(line.replace("ECMAScript 5", "ECMAScript 5: %s" % title))
- else:
- f.write(line)
- if not fileNameExists:
- SC_HELPER.add(fileName)
-
-#------------------------------------------------------------------------------
-class SCAbstraction(object):
- '''
- A class which abstracts working with source control systems in relation to
- generated test262 files. Useful when test262 is also used internally by
- browser implementors.
- '''
- def edit(self, filename):
- '''
- Source control edit of a file. For Mercurial, just make sure it's
- writable.
- '''
- if not(os.stat(filename).st_mode & stat.S_IWRITE):
- os.chmod(filename, stat.S_IWRITE)
-
- def add(self, filename):
- '''
- Source control add of a file.
- '''
- subprocess.call(["hg", "add", filename])
-
-SC_HELPER = SCAbstraction() \ No newline at end of file
diff --git a/tools/TestCaseHTMLPackager/TestUpdater.ps1 b/tools/TestCaseHTMLPackager/TestUpdater.ps1
deleted file mode 100644
index 0bc335ec7..000000000
--- a/tools/TestCaseHTMLPackager/TestUpdater.ps1
+++ /dev/null
Binary files differ
diff --git a/tools/TestCaseHTMLPackager/templates/runner.test262.html b/tools/TestCaseHTMLPackager/templates/runner.test262.html
deleted file mode 100644
index 3bfea29f2..000000000
--- a/tools/TestCaseHTMLPackager/templates/runner.test262.html
+++ /dev/null
@@ -1,170 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd" />
-<html dir="ltr" xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
-<script type="text/javascript" src="resources/scripts/global/jquery-1.4.2.min.js"></script>
-<script type="text/javascript" src="resources/scripts/global/sections.js"></script>
-<script type="text/javascript">
- //Globals
- var TEST_LIST_PATH = "resources/scripts/testcases/testcaseslist.json";
-</script>
-<script type="text/javascript" src="resources/scripts/global/sth.js"></script>
-<script type="text/javascript" src="resources/scripts/global/sta.js"></script>
-<script type="text/javascript" src="resources/scripts/global/jqueryprogressbar.js"></script>
-<script type="text/javascript" src="resources/scripts/global/helper.js"></script>
-<script type="text/javascript" src="resources/scripts/global/jquery.base64.js"></script>
-<script type="text/javascript" src="resources/scripts/global/sputnikLib.js"></script>
-<script type="text/javascript" src="resources/scripts/testcases/SputnikGlobalScope.js"></script>
-<script type="text/javascript" src="resources/scripts/testcases/IETCGlobalScope.js"></script>
-<script language="javascript" type="text/javascript">
- //To support all the browsers
- $(window).resize(ResizeLoadIndicator);
- $(window).load(ResizeLoadIndicator);
- function ResizeLoadIndicator() {
- $(".indicatorContainer .disabledBackground").css({ height: ($(window).height() - 20) + "px" });
- }
-
- $(".indicatorContainer").click(function(e) {
- if (!e) { var e = window.event; }
- e.cancelBubble = true;
- if (e.stopPropagation) { e.stopPropagation(); }
- });
-</script>
-
-<title>ECMAScript Test262</title>
-<link href="resources/styles/style.css" media="screen" rel="stylesheet" title="CSS" type="text/css" />
-</head>
-<body>
- <div class="indicatorContainer" oncontextmenu="return false;">
- <!--Blank div to disable back portion when indicator is shown-->
- <div class="disabledBackground"></div>
- <div id="loadingIndicator">
- <div>
- <img src="./resources/images/spinner.gif" alt="Loading..." />
- <span>Loading...</span>
- </div>
- </div>
- </div>
-
- <div class="wrapper">
- <!-- This Container holds the Logo -->
- <div class="logoHeader">
- <div class="logoBg"><img src="resources/images/logo.png" /></div>
- <div class="ecmascriptbacklink">
- <p><a href='javascript:void(window.open("http://www.ecmascript.org/"));'>ECMAScript.org</a></p>
- </div>
- </div>
- <!-- This Container holds the Navigation -->
- <div class="navBar">
- <ul>
- <li><a href="#" class="selected nav-link" id="home">Home</a></li>
- <li><a href="#" class="nav-link" id="run">Run</a></li>
- <li><a href="#" class="nav-link test-report-link" id="results">Results</a></li>
- <li><a href="#" class="nav-link" id="development">Development</a></li>
- </ul>
- </div>
- <div class="content-container" id="contentContainer">
- <!-- This is the Main Content Container -->
- <div class="content-home">
- <p class="headers">What is test262?</p>
- <p class="content">test262 is a test suite intended to check agreement between JavaScript implementations and the ECMA-262 Specification (currently 5th Edition). The test suite contains thousands of individual tests, each of which tests some specific requirements of the ECMAScript specification.</p>
- <p class="headers">What is ECMAScript?</p>
- <p class="content">"ECMAScript" is the name under which the language more commonly known as "JavaScript" is standardized. Development of the ECMAScript standard is the responsibility of <a href='javascript:void(window.open("http://www.ecma-international.org/memento/TC39.htm"));'>Technical Committee 39 (TC39)</a> of <a href='javascript:void(window.open("http://www.ecma-international.org/"));'>Ecma International</a>. The ECMAScript standard is officially known as ECMA-262. ECMAScript 5 (or just ES5) is short hand for the "ECMA-262, 5th Edition ECMAScript Language Specification" the official name of the current edition of the standard. ECMAScript 5 was approved as an official Ecma standard by the Ecma General Assembly on December 3, 2009. <a href='javascript:void(window.open("http://www.ecma-international.org/publications/files/ECMA-ST/ECMA-262.pdf"));'>The ECMAScript 5 Specification (PDF)</a> is available from the Ecma International web site.</p>
- <p class="headers">Who creates and maintains test262?</p>
- <p class="content">Development of test262 is a project of Ecma TC39. The testing framework and individual tests are created by member organizations of TC39 and contributed to Ecma for use in test262. For more information about how test262 is developed and maintained click the “Development” tab at the top of this page.</p>
- <p class="headers">What is the status of test262?</p>
- <p class="content"><strong>test262 is not yet complete. It is still undergoing active development.</strong> Some portions of the ES5 specification have very complete test coverage while other portions of the specification have only partial test coverage. Some tests may be invalid or may yield false positive or false negative results. A perfect passing score on test262 does not guarantee that a JavaScript implementation perfectly supports ES5. Because tests are being actively added and modified, tests results from different days or times may not be directly comparable. Click the “Development” tab at the top of this page for instructions for reporting test262 bugs.</p>
- <p class="headers">Where can I found out more?</p>
- <p class="content">Please visit our <a href='javascript:void(window.open("http://wiki.ecmascript.org/doku.php?id=test262:faq"));'>Frequently Asked Questions</a> section on the <a href='javascript:void(window.open("http://wiki.ecmascript.org/doku.php?id="));'>ECMAScript Wiki</a>.</p>
-
- <p class="headers">Running the Tests</p>
- <p class="content">Click the “Run” tab at the top of this page for instructions and follow the instructions to run the tests.</p>
-
- <a href='javascript:void(window.open("http://www.ecma-international.org/memento/TC39.htm"));'></a>
-
- </div>
-
- <div class="content-dev">
- <p class="headers">Development</p>
- <p class="content">Test262 is being developed by the members of Ecma TC39. Ecma's intellectual property policies, permit only Ecma
- members to directly contribute code to the project. However, a <a href='javascript:void(window.open("http://mail.mozilla.org/pipermail/test262-discuss/"));'>public mailing list</a> is used to coordinate development of Test262. If you wish to participate in the discussion please <a href='javascript:void(window.open("http://mail.mozilla.org/listinfo/test262-discuss"));'>subscribe</a>. Bug reports and suggestions should be sent to the mailing list.
- </p>
- <p class="content">
- Ecma members can find detailed instructions on Test262 development procedures at the <a href='javascript:void(window.open("http://wiki.ecmascript.org/doku.php?id=test262:test262"));'>Test262 Wiki</a>.
- </p>
- </div>
-
- <div class="content-tests">
- <!-- This is the Main Content Container -->
- <p class="content">Please click on the Start button to start the test. Once you start the test you may pause the test anytime by clicking on the Pause button. You can click on the Results tab once the test is completed or after pausing the test. The Reset button is for restarting the test run.</p>
-<!--
- <div class="progressBarHolder">
- Chapter Index: <input type="text" size="2" maxlength="2" value="" id="chapterId" onkeypress="if(event.keyCode < 48 || event.keyCode > 57){return false;}"/>
- </div>
--->
- <!-- This is the Progress Bar Holder -->
- <div class="progressBarHolder">
- <div id="progressbar"></div>
- <div class="progressBarButtons">
- <img src="resources/images/reset.png" class="button-reset"/>&nbsp;<img src="resources/images/start.png" class="button-start" id="btnStart"/>
- </div>
- <div style="clear: both;"></div>
- </div>
- <p class="hide">>
- Timer Value(ms) : <input id="txtTimerValue" value="50" /> <input id="btnSetTimerValue" value="Set Timer Value" type="button"/>
- </p>
- <!-- This is the Results Text Holder -->
- <div class="resultsHeader">
- <!--Total Loaded: <strong><span id="totalLoadedCounter"></span></strong><span class="Separator">|</span>-->
- Tests To Run: <strong><span class="teststorun-counter" id="testsToRun"></span></strong>&nbsp;<span class="separator">|</span>
- Total Tests Ran: <strong><span class="total-counter" id="totalCounter"></span></strong> <span class="separator">|</span> Pass: <span class="pass" id="Pass"></span> <span class="separator">|</span> Fail: <span class="fail" id="Fail"></span>
- <span class="separator">|</span>&nbsp;Failed To Load: <span class="fail" id="failedToLoadCounter1"></span>
- <p><span id="nextActivity"></span></p>
- </div>
- <!-- This is the Table -->
- <div class="resultsTableHolder" id="tableLoggerParent">
- <table width="100%" border="0" cellspacing="0" cellpadding="0" class="table-logger" id="tableLogger"></table>
- </div>
- <div>
- Test Suite Ver.: <span class="targetTestSuiteVersion"></span>&nbsp;<span class="separator">|</span>&nbsp;Test Suite Date: <span class="targetTestSuiteDate"></span>
- </div>
- </div>
-
- <div class="content-results">
- <div class="crumbContainer">
- <div class="crumbs"></div>
- <div style="float:right;"><a class="setBlue hide" id="backlinkDiv" href="#"><< back</a></div>
- <div style="clear : both;"></div>
- </div>
- <div class="resultsHeader"> <strong>Total Tests:<span class="totalCases"></span></strong><br />
- Passed: <span class="passedCases"></span> <span class="separator">|</span> Failed: <span class="failedCases"></span> <span class="separator">|</span>
- Failed To Load: <strong><span id="failedToLoadCounter"></span></strong>
- </div>
- <!-- This is the Table -->
- <div class="resultsTableHolder">
- <table width="100%" cellspacing="0" cellpadding="0" border="0" class="results-data-table"> </table>
- <div id="resultMessage">Test results will be displayed after the tests are executed using the Run page.</div>
- </div>
- <div>
- Test Suite Ver.: <span class="targetTestSuiteVersion"></span>&nbsp;<span class="separator">|</span>&nbsp;Test Suite Date: <span class="targetTestSuiteDate"></span>
- </div>
- <div class="downloadLinks">
- <p><a class="anchor-download-xml" id="ancGenXMLReport"><strong>Download results as XML</strong></a></p> <!--| <strong><a href="resources/scripts/testcases.zip">Download Source</a></strong></p>-->
- </div>
- <div id="legend" class="hide">
- <label class="reportGreen">Green:</label>&nbsp;100%&nbsp;
- <label class="reportLightGreen">Green:</label>&nbsp;75% to 99.9%&nbsp;
- <label class="reportYellow">Yellow:</label>&nbsp;50% to 75% &nbsp;
- <label class="reportRed">Red:</label>&nbsp;less than 50%
- </div>
- </div>
- </div>
- </div>
- <!-- This is the Footer -->
- <div class="footer">
- <!--<div class="Links"> <a href="">Privacy</a> | <a href="">Terms of Use</a> </div>-->
- <div class="copyright"> &copy; <a href='javascript:void(window.open("http://www.ecma-international.org"));'>Ecma International</a> </div>
- </div>
- <iframe id="scriptLoader" class="hide"></iframe>
-</body>
-</html>