nixosTests.yq: remove, move to yq package

This commit is contained in:
Patrick Hilhorst 2021-10-28 14:06:05 +02:00
parent e29cb6cb57
commit 4dc3596fd1
No known key found for this signature in database
GPG key ID: 3BB083304DADC0FF
3 changed files with 4 additions and 14 deletions

View file

@ -498,7 +498,6 @@ in
xterm = handleTest ./xterm.nix {}; xterm = handleTest ./xterm.nix {};
yabar = handleTest ./yabar.nix {}; yabar = handleTest ./yabar.nix {};
yggdrasil = handleTest ./yggdrasil.nix {}; yggdrasil = handleTest ./yggdrasil.nix {};
yq = handleTest ./yq.nix {};
zfs = handleTest ./zfs.nix {}; zfs = handleTest ./zfs.nix {};
zigbee2mqtt = handleTest ./zigbee2mqtt.nix {}; zigbee2mqtt = handleTest ./zigbee2mqtt.nix {};
zoneminder = handleTest ./zoneminder.nix {}; zoneminder = handleTest ./zoneminder.nix {};

View file

@ -1,12 +0,0 @@
import ./make-test-python.nix ({ pkgs, ... }: {
name = "yq";
meta = with pkgs.lib.maintainers; { maintainers = [ nequissimus ]; };
nodes.yq = { pkgs, ... }: { environment.systemPackages = with pkgs; [ jq yq ]; };
testScript = ''
assert "hello:\n foo: bar\n" in yq.succeed(
'echo \'{"hello":{"foo":"bar"}}\' | yq -y .'
)
'';
})

View file

@ -45,7 +45,10 @@ buildPythonPackage rec {
pythonImportsCheck = [ "yq" ]; pythonImportsCheck = [ "yq" ];
passthru.tests = { inherit (nixosTests) yq; }; doInstallCheck = true;
installCheckPhase = ''
echo '{"hello":{"foo":"bar"}}' | $out/bin/yq -y . | grep 'foo: bar'
'';
meta = with lib; { meta = with lib; {
description = "Command-line YAML processor - jq wrapper for YAML documents"; description = "Command-line YAML processor - jq wrapper for YAML documents";