Files
hearth/test/package/affine/default.nix
T
yukkop e935abd0c3
runner nix smoke / nix label and flake smoke (push) Failing after 1m55s
affine fix styles
2026-10-29 21:43:33 +00:00

29 lines
936 B
Nix

{ system, self, pkgs, ... }:
let
runtimeInputs = [
pkgs.dash
pkgs.curl
pkgs.jq
pkgs.nodejs_22
(pkgs.postgresql_16.withPackages (ps: [ ps.pgvector ]))
pkgs.redis
];
check = name: extra: pkgs.runCommand name ({
nativeBuildInputs = runtimeInputs;
AFFINE_PACKAGE = self.packages.${system}.affine;
AFFINE_CLIENT_TEST = ./test/client.cjs;
} // extra) ''
dash ${./test/runtime.sh}
touch "$out"
'';
in pkgs.lib.optionalAttrs (system == "x86_64-linux") {
affine-runtime = check "affine-runtime" {};
affine-typography = check "affine-typography" {
nativeBuildInputs = runtimeInputs ++ [ pkgs.playwright-driver ];
PLAYWRIGHT_CORE_PATH = "${pkgs.playwright-driver}";
PLAYWRIGHT_BROWSERS_PATH = "${pkgs.playwright-driver.browsers}";
AFFINE_TYPOGRAPHY_TEST = ./test/typography.cjs;
AFFINE_TYPOGRAPHY_PATCH = ../../../package/affine/gitea-document-typography.patch;
};
}