mirror of
https://github.com/nix-community/nixvim.git
synced 2025-08-03 17:45:03 +02:00
tests: cleanup tests to better use callTest
pattern
e.g. Prefer taking `pkgs.*` attrs directly as function arguments.
This commit is contained in:
parent
4a508ceee2
commit
036e11665f
7 changed files with 33 additions and 20 deletions
|
@ -1,4 +1,7 @@
|
|||
{ makeNixvimWithModule, pkgs }:
|
||||
{
|
||||
makeNixvimWithModule,
|
||||
runCommandNoCCLocal,
|
||||
}:
|
||||
let
|
||||
firstStage = makeNixvimWithModule {
|
||||
module = {
|
||||
|
@ -10,7 +13,7 @@ let
|
|||
|
||||
generated = secondStage.extend { extraConfigLua = "-- third stage"; };
|
||||
in
|
||||
pkgs.runCommand "extend-test" { printConfig = "${generated}/bin/nixvim-print-init"; } ''
|
||||
runCommandNoCCLocal "extend-test" { printConfig = "${generated}/bin/nixvim-print-init"; } ''
|
||||
config=$($printConfig)
|
||||
for stage in "first" "second" "third"; do
|
||||
if ! "$printConfig" | grep -q -- "-- $stage stage"; then
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue