mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
28 lines
808 B
HTML
28 lines
808 B
HTML
|
<!DOCTYPE html>
|
||
|
<html>
|
||
|
<head>
|
||
|
<title> WorkerLocation URL decomposition IDL attribute: pathname </title>
|
||
|
<script src="/resources/testharness.js"></script>
|
||
|
<script src="/resources/testharnessreport.js"></script>
|
||
|
</head>
|
||
|
<body>
|
||
|
<div id=log></div>
|
||
|
<script>
|
||
|
|
||
|
var FileName = './support/WorkerLocation.js';
|
||
|
var pathname = window.location.pathname;
|
||
|
var ExpectedResult = pathname.substring(0, pathname.lastIndexOf('/')) + FileName.substring(1);
|
||
|
|
||
|
var t = async_test("Test Description: WorkerLocation pathname attribute returns the current path in the underlying URL.");
|
||
|
|
||
|
var worker = new Worker(FileName);
|
||
|
|
||
|
worker.onmessage = t.step_func(function(evt)
|
||
|
{
|
||
|
assert_equals(evt.data.pathname, ExpectedResult);
|
||
|
t.done();
|
||
|
});
|
||
|
</script>
|
||
|
</body>
|
||
|
</html>
|