summaryrefslogtreecommitdiff
path: root/tests/fonts.nix
diff options
context:
space:
mode:
Diffstat (limited to 'tests/fonts.nix')
-rw-r--r--tests/fonts.nix15
1 files changed, 6 insertions, 9 deletions
diff --git a/tests/fonts.nix b/tests/fonts.nix
index acd1b13..d60979c 100644
--- a/tests/fonts.nix
+++ b/tests/fonts.nix
@@ -2,22 +2,19 @@
let
font = pkgs.runCommand "font-0.0.0" {} ''
- mkdir -p $out/share/fonts
- touch $out/share/fonts/Font.ttf
+ mkdir -p $out
+ touch $out/Font.ttf
'';
in
{
- fonts.fontDir.enable = true;
- fonts.fonts = [ font ];
+ fonts.packages = [ font ];
test = ''
- echo "checking fonts in /Library/Fonts" >&2
- test -e ${config.out}/Library/Fonts/Font.ttf
+ echo "checking fonts in /Library/Fonts/Nix Fonts" >&2
+ test -e "${config.out}/Library/Fonts/Nix Fonts"/*/Font.ttf
echo "checking activation of fonts in /activate" >&2
- grep "fontrestore default -n 2>&1" ${config.out}/activate
- grep 'ln -fn ".*" /Library/Fonts' ${config.out}/activate || grep 'rsync -az --inplace ".*" /Library/Fonts' ${config.out}/activate
- grep 'rm "/Library/Fonts/.*"' ${config.out}/activate
+ grep '/Library/Fonts/Nix Fonts' ${config.out}/activate
'';
}