Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions nix-ci.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
test.test-suite = {
package = "packages.x86_64-linux.test-suite";
in-repo = true;
};
}
21 changes: 21 additions & 0 deletions nix/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,25 @@ rec {
devShell = pkgs.callPackage ./devshell { nix-editor = nix-editor-pkg; };
fmt = pkgs.callPackage ./fmt { };
upm = pkgs.callPackage ./upm { inherit self rev; };
test-suite = pkgs.writeShellApplication {
name = "upm-test-suite";
runtimeInputs = [
upm
pkgs.bash
pkgs.gotestsum
pkgs.git
pkgs.coreutils
pkgs.stdenv.cc
] ++ devShell.nativeBuildInputs;
text = ''
venv=$(mktemp -d)
trap 'rm -rf "$venv"' EXIT
python -m venv "$venv"
export VIRTUAL_ENV="$venv"
export PATH="$VIRTUAL_ENV/bin:$PATH"
export npm_config_script_shell="${pkgs.bash}/bin/sh"
export UV_PYTHON="${pkgs.python311}/bin/python3.11"
gotestsum --junitfile junit.xml -- -count=1 ./test-suite
'';
};
}
Loading