From c7fbae128947d4c656e40386c2ab5c4337f03ecd Mon Sep 17 00:00:00 2001 From: Martin Weinelt Date: Fri, 9 Dec 2022 01:38:22 +0100 Subject: [PATCH] nixos/tests/prometheus-exporters.smartctl: update test script We can't actually get metrics for a virtual disk drive so the exporter fails to start with 0.9.x. Instead let's just make sure it said that /dev/vda was unavailable. --- nixos/tests/prometheus-exporters.nix | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/nixos/tests/prometheus-exporters.nix b/nixos/tests/prometheus-exporters.nix index cdf666378fa3..8b40d7e41c00 100644 --- a/nixos/tests/prometheus-exporters.nix +++ b/nixos/tests/prometheus-exporters.nix @@ -1086,13 +1086,8 @@ let ]; }; exporterTest = '' - wait_for_unit("prometheus-smartctl-exporter.service") - wait_for_open_port(9633) wait_until_succeeds( - "curl -sSf 'localhost:9633/metrics'" - ) - wait_until_succeeds( - 'journalctl -eu prometheus-smartctl-exporter.service -o cat | grep "/dev/vda: Unable to detect device type"' + 'journalctl -eu prometheus-smartctl-exporter.service -o cat | grep "Device unavailable"' ) ''; };