diff --git a/tools/packaging/TestCasePackagerConfig.py b/tools/packaging/TestCasePackagerConfig.py index 9364556d70..e92f27b933 100644 --- a/tools/packaging/TestCasePackagerConfig.py +++ b/tools/packaging/TestCasePackagerConfig.py @@ -26,12 +26,11 @@ import stat #--Globals--------------------------------------------------------------------- MAX_CASES_PER_JSON = 1000 +WEBSITE_SHORT_NAME = "website2" + #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"] +TEST_CONTRIB_DIRS = ["converted"] #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__)), "..", "..") @@ -45,18 +44,19 @@ TEST262_CASES_DIR = os.path.join(TEST262_ROOT, "test", "suite") 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") +TEST262_WEB_CASES_DIR = os.path.join(TEST262_ROOT, WEBSITE_SHORT_NAME, "json") #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") +TEST262_WEB_HARNESS_DIR = os.path.join(TEST262_ROOT, WEBSITE_SHORT_NAME, "harness") #Path to the ported test case files on the actual website as opposed to the Hg layout -WEBSITE_CASES_PATH = "resources/scripts/testcases/" +WEBSITE_CASES_PATH = "json/" #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 @@ -70,7 +70,7 @@ def generateHarness(harnessType, jsonName, title): 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")) + fileName = os.path.join(TEST262_ROOT, WEBSITE_SHORT_NAME, jsonName.replace(".json", ".html")) fileNameExists = False if os.path.exists(fileName): SC_HELPER.edit(fileName) diff --git a/tools/packaging/common.py b/tools/packaging/common.py new file mode 100644 index 0000000000..ba4ffba5dd --- /dev/null +++ b/tools/packaging/common.py @@ -0,0 +1,13 @@ +#--Imports--------------------------------------------------------------------- + +#--Stubs----------------------------------------------------------------------- + + + +#--Globals--------------------------------------------------------------------- + + +#--Helpers--------------------------------------------------------------------# + + +#--MAIN------------------------------------------------------------------------ diff --git a/tools/packaging/packager.py b/tools/packaging/packager.py index 7c7a02d145..f1ee23e5f4 100644 --- a/tools/packaging/packager.py +++ b/tools/packaging/packager.py @@ -1,4 +1,4 @@ -# Copyright (c) 2009 Microsoft Corporation +# Copyright (c) 2011 Microsoft Corporation # # Redistribution and use in source and binary forms, with or without modification, are permitted provided # that the following conditions are met: @@ -291,18 +291,4 @@ if TEST262_HARNESS_DIR!=TEST262_WEB_HARNESS_DIR: 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/packaging/templates/runner.test262.html b/tools/packaging/templates/runner.test262.html index 3bfea29f25..47331606f0 100644 --- a/tools/packaging/templates/runner.test262.html +++ b/tools/packaging/templates/runner.test262.html @@ -2,20 +2,18 @@ - - + + - - - - - - - - + + + + + + ECMAScript Test262 - +
@@ -40,7 +38,7 @@
- Loading... + Loading... Loading...
@@ -49,7 +47,7 @@
-
+
@@ -106,7 +104,7 @@
-   +  
@@ -149,7 +147,7 @@ Test Suite Ver.:  | Test Suite Date:
 100%  diff --git a/website/resources/images/back.png b/website/images/back.png similarity index 100% rename from website/resources/images/back.png rename to website/images/back.png diff --git a/website/resources/images/button_bg.png b/website/images/button_bg.png similarity index 100% rename from website/resources/images/button_bg.png rename to website/images/button_bg.png diff --git a/website/resources/images/ecmascriptlogo.png b/website/images/ecmascriptlogo.png similarity index 100% rename from website/resources/images/ecmascriptlogo.png rename to website/images/ecmascriptlogo.png diff --git a/website/resources/images/fade.jpg b/website/images/fade.jpg similarity index 100% rename from website/resources/images/fade.jpg rename to website/images/fade.jpg diff --git a/website/resources/images/logo.png b/website/images/logo.png similarity index 100% rename from website/resources/images/logo.png rename to website/images/logo.png diff --git a/website/resources/images/pause.png b/website/images/pause.png similarity index 100% rename from website/resources/images/pause.png rename to website/images/pause.png diff --git a/website/resources/images/progressbarbg.png b/website/images/progressbarbg.png similarity index 100% rename from website/resources/images/progressbarbg.png rename to website/images/progressbarbg.png diff --git a/website/resources/images/rerun.png b/website/images/rerun.png similarity index 100% rename from website/resources/images/rerun.png rename to website/images/rerun.png diff --git a/website/resources/images/reset.png b/website/images/reset.png similarity index 100% rename from website/resources/images/reset.png rename to website/images/reset.png diff --git a/website/resources/images/resume.png b/website/images/resume.png similarity index 100% rename from website/resources/images/resume.png rename to website/images/resume.png diff --git a/website/resources/images/selectedbutton_bg.png b/website/images/selectedbutton_bg.png similarity index 100% rename from website/resources/images/selectedbutton_bg.png rename to website/images/selectedbutton_bg.png diff --git a/website/resources/images/spinner.gif b/website/images/spinner.gif similarity index 100% rename from website/resources/images/spinner.gif rename to website/images/spinner.gif diff --git a/website/resources/images/splitter.png b/website/images/splitter.png similarity index 100% rename from website/resources/images/splitter.png rename to website/images/splitter.png diff --git a/website/resources/images/start.png b/website/images/start.png similarity index 100% rename from website/resources/images/start.png rename to website/images/start.png diff --git a/website/resources/images/stop.png b/website/images/stop.png similarity index 100% rename from website/resources/images/stop.png rename to website/images/stop.png diff --git a/website/resources/images/tblheaderbg.png b/website/images/tblheaderbg.png similarity index 100% rename from website/resources/images/tblheaderbg.png rename to website/images/tblheaderbg.png diff --git a/website/resources/images/tblreportheaderbg.png b/website/images/tblreportheaderbg.png similarity index 100% rename from website/resources/images/tblreportheaderbg.png rename to website/images/tblreportheaderbg.png diff --git a/website/resources/images/tblsectionheader.png b/website/images/tblsectionheader.png similarity index 100% rename from website/resources/images/tblsectionheader.png rename to website/images/tblsectionheader.png diff --git a/website/resources/images/tc39.png b/website/images/tc39.png similarity index 100% rename from website/resources/images/tc39.png rename to website/images/tc39.png diff --git a/website/resources/styles/style.css b/website/styles/style.css similarity index 100% rename from website/resources/styles/style.css rename to website/styles/style.css