forked from web-platform-tests/wpt
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Split jssp wpt tests into single test files
Runtimes on linux-rel ranges from 4s to 12s rendering the test flaky on default timeouts. Due to the nature of the tests busy waiting to ensure a sample is captured, breaking JSSP wpt tests into single test files should help. Bug: chromium:1226936 Change-Id: Ib113f85510a4c9b0bcdcdc10c540565a41d300f4 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3406580 Auto-Submit: Corentin Pescheloche <[email protected]> Reviewed-by: Nicolás Peña <[email protected]> Commit-Queue: Nicolás Peña <[email protected]> Cr-Commit-Position: refs/heads/main@{#962169}
- Loading branch information
1 parent
f8925dd
commit 45db93f
Showing
7 changed files
with
162 additions
and
84 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
|
||
<head> | ||
<script src="/resources/testharness.js"></script> | ||
<script src="/resources/testharnessreport.js"></script> | ||
|
||
<script src="resources/profile-utils.js"></script> | ||
</head> | ||
|
||
<body> | ||
<script> | ||
// Getter methods should use `get ${label}` as the function/frame name. Source: | ||
// https://www.ecma-international.org/ecma-262/#sec-method-definitions-runtime-semantics-propertydefinitionevaluation | ||
promise_test(t => ProfileUtils.testFunction(sample => { | ||
class SomeClass { | ||
get someValue() { | ||
sample(); | ||
} | ||
} | ||
let instance = new SomeClass(); | ||
instance.someValue; | ||
}, { | ||
name: 'get someValue', | ||
} | ||
), 'class getter names are logged correctly'); | ||
</script> | ||
</body> | ||
|
||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
|
||
<head> | ||
<script src="/resources/testharness.js"></script> | ||
<script src="/resources/testharnessreport.js"></script> | ||
|
||
<script src="resources/profile-utils.js"></script> | ||
</head> | ||
|
||
<body> | ||
<script> | ||
// Methods should use their label as the function/frame name. Source: | ||
// https://www.ecma-international.org/ecma-262/#sec-method-definitions-runtime-semantics-propertydefinitionevaluation | ||
promise_test(async t => { | ||
class SomeClass { | ||
method(sample) { | ||
sample(); | ||
} | ||
} | ||
let instance = new SomeClass(); | ||
|
||
await ProfileUtils.testFunction(instance.method.bind(instance), { | ||
name: 'method', | ||
}); | ||
}, 'class method names are logged correctly'); | ||
</script> | ||
</body> | ||
|
||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
|
||
<head> | ||
<script src="/resources/testharness.js"></script> | ||
<script src="/resources/testharnessreport.js"></script> | ||
|
||
<script src="resources/profile-utils.js"></script> | ||
</head> | ||
|
||
<body> | ||
<script> | ||
// Setter methods should use `set ${label}` as the function/frame name. Source: | ||
// https://www.ecma-international.org/ecma-262/#sec-method-definitions-runtime-semantics-propertydefinitionevaluation | ||
promise_test(t => ProfileUtils.testFunction(sample => { | ||
class SomeClass { | ||
set someValue(_) { | ||
sample(); | ||
} | ||
} | ||
let instance = new SomeClass(); | ||
instance.someValue = 5; | ||
}, { | ||
name: 'set someValue', | ||
} | ||
), 'class setter names are logged correctly'); | ||
</script> | ||
</body> | ||
|
||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
|
||
<head> | ||
<script src="/resources/testharness.js"></script> | ||
<script src="/resources/testharnessreport.js"></script> | ||
|
||
<script src="resources/profile-utils.js"></script> | ||
</head> | ||
|
||
<body> | ||
<script> | ||
promise_test(async t => { | ||
const f = function (sample) { | ||
sample(); | ||
}; | ||
await ProfileUtils.testFunction(f, { | ||
name: '', | ||
}); | ||
}, 'anonymous function expression names are logged correctly'); | ||
</script> | ||
</body> | ||
|
||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
|
||
<head> | ||
<script src="/resources/testharness.js"></script> | ||
<script src="/resources/testharnessreport.js"></script> | ||
|
||
<script src="resources/profile-utils.js"></script> | ||
</head> | ||
|
||
<body> | ||
<script> | ||
promise_test(async t => { | ||
function namedFunctionDeclaration(sample) { | ||
sample(); | ||
}; | ||
await ProfileUtils.testFunction(namedFunctionDeclaration, { | ||
name: 'namedFunctionDeclaration', | ||
}); | ||
}, 'function declaration names are logged correctly'); | ||
</script> | ||
</body> | ||
|
||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
|
||
<head> | ||
<script src="/resources/testharness.js"></script> | ||
<script src="/resources/testharnessreport.js"></script> | ||
|
||
<script src="resources/profile-utils.js"></script> | ||
</head> | ||
|
||
<body> | ||
<script> | ||
promise_test(async t => { | ||
const f = function namedFunctionExpression(sample) { | ||
sample(); | ||
}; | ||
await ProfileUtils.testFunction(f, { | ||
name: 'namedFunctionExpression', | ||
}); | ||
}, 'function expression names are logged correctly'); | ||
</script> | ||
</body> | ||
|
||
</html> |
This file was deleted.
Oops, something went wrong.