mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-03 08:08:43 +00:00
Tests/LibWeb: Move assets used by multiple test types into Assets/
Having to go through multiple levels of .. is not ideal, but less odd than reaching into another test type's data files.
This commit is contained in:
parent
57ba720fb1
commit
08253d6aee
Notes:
github-actions[bot]
2024-11-05 16:45:25 +00:00
Author: https://github.com/AtkinsSJ
Commit: 08253d6aee
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/2175
Reviewed-by: https://github.com/gmta ✅
25 changed files with 27 additions and 27 deletions
|
@ -21,7 +21,7 @@
|
|||
println(`zeroBytesFace.family: ${zeroBytesFace.family}`); // "Empty Font"
|
||||
});
|
||||
|
||||
const fontData = await fetch("../../../Ref/assets/HashSans.woff").then(
|
||||
const fontData = await fetch("../../../Assets/HashSans.woff").then(
|
||||
response => response.arrayBuffer(),
|
||||
(reason) => {
|
||||
println(`FAILED to fetch font from local file ${reason}`);
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
// FIXME: Surely there's a better way to get this font URL
|
||||
let fontUrl = new URL(location.href);
|
||||
fontUrl.search = "";
|
||||
fontUrl += "/../../../../Ref/assets/HashSans.woff";
|
||||
fontUrl += "/../../../../Assets/HashSans.woff";
|
||||
|
||||
const hashSans = new FontFace("Hash Sans", `url(${fontUrl})`);
|
||||
println(`hashSans.family: ${hashSans.family}`);
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
asyncTest(async done => {
|
||||
const fontFaceSet = document.fonts;
|
||||
|
||||
const fontFace = new FontFace("Hash Sans", "url(../../../../Ref/assets/HashSans.woff)");
|
||||
const fontFace = new FontFace("Hash Sans", "url(../../../../Assets/HashSans.woff)");
|
||||
fontFaceSet.add(fontFace);
|
||||
|
||||
try {
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<script>
|
||||
test(() => {
|
||||
const fontFaceSet = document.fonts;
|
||||
const fontFace = new FontFace("Hash Sans", 'url(../../../../Ref/assets/HashSans.woff)');
|
||||
const fontFace = new FontFace("Hash Sans", 'url(../../../../Assets/HashSans.woff)');
|
||||
|
||||
println("-- Empty FontFaceSet --");
|
||||
println(`fontFaceSet.size: ${fontFaceSet.size}`);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue