mirror of
https://github.com/SerenityOS/serenity.git
synced 2025-01-22 09:21:57 -05:00
Meta+Tests: Substitute Ahem font path in import-wpt-test.py
(cherry picked from commit 3833049fc8680d4e6349511cf566f27a25225ada)
This commit is contained in:
parent
c4b4f293e9
commit
ff4c99ec0a
3 changed files with 8 additions and 0 deletions
|
@ -66,6 +66,8 @@ def modify_sources(files):
|
||||||
with open(file, 'r') as f:
|
with open(file, 'r') as f:
|
||||||
page_source = f.read()
|
page_source = f.read()
|
||||||
|
|
||||||
|
page_source = page_source.replace('/fonts/ahem.css', '../' * parent_folder_count + 'fonts/ahem.css')
|
||||||
|
|
||||||
# Iterate all scripts and overwrite the src attribute
|
# Iterate all scripts and overwrite the src attribute
|
||||||
for i, src_value in enumerate(src_values):
|
for i, src_value in enumerate(src_values):
|
||||||
if src_value.startswith('/'):
|
if src_value.startswith('/'):
|
||||||
|
|
BIN
Tests/LibWeb/Text/input/wpt-import/fonts/Ahem.ttf
Normal file
BIN
Tests/LibWeb/Text/input/wpt-import/fonts/Ahem.ttf
Normal file
Binary file not shown.
6
Tests/LibWeb/Text/input/wpt-import/fonts/ahem.css
Normal file
6
Tests/LibWeb/Text/input/wpt-import/fonts/ahem.css
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
@font-face {
|
||||||
|
font-family: 'Ahem';
|
||||||
|
src: local('Ahem'),
|
||||||
|
url('Ahem.ttf');
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in a new issue