nixpkgs/nixos/tests/web-apps/rss-bridge.nix
Mynacol b444a0e028 rss-bridge: Add simple NixOS test
Add a simple test that starts rss-bridge and tries to fetch the feed of
a demo bridge. On success we know the system setup (web server, PHP) and
rss-bridge are working fine. Internet access is avoided by using a demo
bridge.
2024-08-01 16:55:09 +02:00

23 lines
512 B
Nix

{ pkgs, ... }:
{
name = "rss-bridge";
meta.maintainers = with pkgs.lib.maintainers; [ mynacol ];
nodes.machine =
{ ... }:
{
services.rss-bridge = {
enable = true;
};
};
testScript = ''
start_all()
machine.wait_for_unit("nginx.service")
machine.wait_for_unit("phpfpm-rss-bridge.service")
# check for successful feed download
machine.succeed("curl -sS -f 'http://localhost/?action=display&bridge=DemoBridge&context=testCheckbox&format=Atom'")
'';
}