mirror of
https://github.com/DoneJS-Runtime/quickjs-done-nextgen.git
synced 2025-01-09 17:43:15 +00:00
Remove obsolete run-test262 style option
We always run the test262 suite in new-style mode.
This commit is contained in:
parent
3c3c487e11
commit
79eee54b22
2 changed files with 82 additions and 139 deletions
|
@ -76,7 +76,6 @@ enum test_mode_t {
|
|||
} test_mode = TEST_DEFAULT_NOSTRICT;
|
||||
int skip_async;
|
||||
int skip_module;
|
||||
int new_style;
|
||||
int dump_memory;
|
||||
int stats_count;
|
||||
JSMemoryUsage stats_all, stats_avg, stats_min, stats_max;
|
||||
|
@ -1130,10 +1129,6 @@ void load_config(const char *filename, const char *ignore)
|
|||
printf("%s:%d: ignoring %s=%s\n", filename, lineno, p, q);
|
||||
continue;
|
||||
}
|
||||
if (str_equal(p, "style")) {
|
||||
new_style = str_equal(q, "new");
|
||||
continue;
|
||||
}
|
||||
if (str_equal(p, "testdir")) {
|
||||
char *testdir = compose_path(base_name, q);
|
||||
enumerate_tests(testdir);
|
||||
|
@ -1754,7 +1749,6 @@ int run_test(const char *filename, int *msec)
|
|||
|
||||
harness = harness_dir;
|
||||
|
||||
if (new_style) {
|
||||
if (!harness) {
|
||||
p = strstr(filename, "test/");
|
||||
if (p) {
|
||||
|
@ -1839,51 +1833,6 @@ int run_test(const char *filename, int *msec)
|
|||
}
|
||||
if (is_async)
|
||||
namelist_add(ip, NULL, "doneprintHandle.js");
|
||||
} else {
|
||||
char *ifile;
|
||||
|
||||
if (!harness) {
|
||||
p = strstr(filename, "test/");
|
||||
if (p) {
|
||||
snprintf(harnessbuf, sizeof(harnessbuf), "%.*s%s",
|
||||
(int)(p - filename), filename, "test/harness");
|
||||
}
|
||||
harness = harnessbuf;
|
||||
}
|
||||
|
||||
namelist_add(ip, NULL, "sta.js");
|
||||
|
||||
/* include extra harness files */
|
||||
for (p = buf; (p = strstr(p, "$INCLUDE(\"")) != NULL; p++) {
|
||||
p += 10;
|
||||
ifile = strdup_len(p, strcspn(p, "\""));
|
||||
// skip unsupported harness files
|
||||
if (find_word(harness_exclude, ifile)) {
|
||||
skip |= 1;
|
||||
} else {
|
||||
namelist_add(ip, NULL, ifile);
|
||||
}
|
||||
free(ifile);
|
||||
}
|
||||
|
||||
/* locate the old style configuration comment */
|
||||
desc = extract_desc(buf, '*');
|
||||
if (desc) {
|
||||
if (strstr(desc, "@noStrict")) {
|
||||
is_nostrict = TRUE;
|
||||
skip |= (test_mode == TEST_STRICT);
|
||||
}
|
||||
if (strstr(desc, "@onlyStrict")) {
|
||||
is_onlystrict = TRUE;
|
||||
skip |= (test_mode == TEST_NOSTRICT);
|
||||
}
|
||||
if (strstr(desc, "@negative")) {
|
||||
/* XXX: should extract the regex to check error type */
|
||||
is_negative = TRUE;
|
||||
}
|
||||
free(desc);
|
||||
}
|
||||
}
|
||||
|
||||
use_strict = use_nostrict = 0;
|
||||
/* XXX: should remove 'test_mode' or simplify it just to force
|
||||
|
@ -2086,7 +2035,6 @@ void help(void)
|
|||
"-h help\n"
|
||||
"-a run tests in strict and nostrict modes\n"
|
||||
"-m print memory usage summary\n"
|
||||
"-n use new style harness\n"
|
||||
"-N run test prepared by test262-harness+eshost\n"
|
||||
"-s run tests in strict mode, skip @nostrict tests\n"
|
||||
"-E only run tests from the error file\n"
|
||||
|
@ -2159,8 +2107,6 @@ int main(int argc, char **argv)
|
|||
help();
|
||||
} else if (str_equal(arg, "-m")) {
|
||||
dump_memory++;
|
||||
} else if (str_equal(arg, "-n")) {
|
||||
new_style++;
|
||||
} else if (str_equal(arg, "-s")) {
|
||||
test_mode = TEST_STRICT;
|
||||
} else if (str_equal(arg, "-a")) {
|
||||
|
|
|
@ -1,9 +1,6 @@
|
|||
[config]
|
||||
# general settings for test262 ES6 version
|
||||
|
||||
# framework style: old, new
|
||||
style=new
|
||||
|
||||
# handle tests tagged as [noStrict]: yes, no, skip
|
||||
nostrict=yes
|
||||
|
||||
|
|
Loading…
Reference in a new issue