1 import ./make-test-python.nix ({ pkgs, ... }:
4 meta = with pkgs.lib.maintainers; {
5 maintainers = [ dandellion ];
13 services.redis.servers."".enable = true;
15 environment.systemPackages = with pkgs; [ (python3.withPackages (ps: [ ps.twisted ps.txredisapi ps.mock ]))];
19 testScript = { nodes, ... }: let
20 inherit (nodes.machine.config.services) redis;
23 machine.wait_for_unit("redis")
24 machine.wait_for_file("${redis.servers."".unixSocket}")
25 machine.succeed("ln -s ${redis.servers."".unixSocket} /tmp/redis.sock")
27 tests = machine.succeed("PYTHONPATH=\"${pkgs.python3Packages.txredisapi.src}\" python -m twisted.trial ${pkgs.python3Packages.txredisapi.src}/tests")