mirror of
https://github.com/LnL7/nix-darwin.git
synced 2025-03-15 21:08:21 +00:00
tests: avoid depending on an actual font package
This commit is contained in:
parent
9a04aea8ea
commit
5fa894c90a
1 changed files with 10 additions and 7 deletions
|
@ -1,17 +1,20 @@
|
||||||
{ config, pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
let
|
let
|
||||||
fonts = pkgs.runCommand "fonts-0.0.0" {} "mkdir -p $out";
|
font = pkgs.runCommand "font-0.0.0" {} ''
|
||||||
in {
|
mkdir -p $out/share/fonts
|
||||||
fonts = {
|
touch $out/share/fonts/Font.ttf
|
||||||
enableFontDir = true;
|
'';
|
||||||
fonts = [ pkgs.dejavu_fonts ];
|
in
|
||||||
};
|
|
||||||
|
{
|
||||||
|
fonts.enableFontDir = true;
|
||||||
|
fonts.fonts = [ font ];
|
||||||
|
|
||||||
test = ''
|
test = ''
|
||||||
echo checking installed fonts >&2
|
echo checking installed fonts >&2
|
||||||
grep -o "fontrestore default -n" ${config.out}/activate
|
grep -o "fontrestore default -n" ${config.out}/activate
|
||||||
grep -o "ln -fn '/run/current-system/sw/share/fonts/DejaVuSans.ttf' '/Library/Fonts/DejaVuSans.ttf'" ${config.out}/activate
|
grep -o "ln -fn '/run/current-system/sw/share/fonts/Font.ttf' '/Library/Fonts/Font.ttf'" ${config.out}/activate
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue