File: 0017-use-Roboto-font-embedded-in-Debian-package.patch

package info (click to toggle)
openqa 5.1764349525.ffb594867-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 18,264 kB
  • sloc: perl: 57,599; sql: 26,462; javascript: 8,466; xml: 2,229; sh: 1,705; makefile: 443; python: 249
file content (40 lines) | stat: -rw-r--r-- 1,502 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
From: Philip Hands <phil@hands.com>
Date: Mon, 16 Dec 2024 23:25:36 +0100
Subject: use Roboto font embedded in Debian package

---
 assets/stylesheets/openqa.scss | 7 +++++--
 t/25-serverstartup.t           | 2 +-
 2 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/assets/stylesheets/openqa.scss b/assets/stylesheets/openqa.scss
index e7952a3..706c0e5 100644
--- a/assets/stylesheets/openqa.scss
+++ b/assets/stylesheets/openqa.scss
@@ -2,8 +2,11 @@
 // include themes: these set variables for common values
 @import "openqa_theme.scss";
 
-// include Roboto font
-@import url($web-font-path);
+// use Roboto font from embedded build dependency on Debian
+@font-face {
+  font-family: 'Roboto';
+  src: url('/fonts/Roboto-Regular.ttf') format('truetype');
+}
 
 // prevent bom from disturbing rest of the CSS
 dummy { font-size: 42px; }
diff --git a/t/25-serverstartup.t b/t/25-serverstartup.t
index e9aa66d..2cddb8e 100644
--- a/t/25-serverstartup.t
+++ b/t/25-serverstartup.t
@@ -181,7 +181,7 @@ subtest 'Update configuration from Plugin requirements' => sub {
 subtest 'listing assets (for installation/Makefile)' => sub {
     my $app = Mojolicious->new(home => Mojo::Home->new("$FindBin::Bin/.."));
     my $output = combined_from { OpenQA::Assets::list($app) };
-    my @expected_extensions = qw(scss css js png svg ttf);
+    my @expected_extensions = qw(scss css js png svg);
     like $output, qr{^(assets|node_modules)/.*\.$_$}m, "$_ file listed" for @expected_extensions;
 };