summaryrefslogtreecommitdiff
path: root/pkgs/development/python-modules/bork/tests.nix
blob: 7d5c84f2bc35cb00e29a18af31cdf3f619352e81 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
{
  testers,

  bork,
  cacert,
  git,
  pytest,
}:
{
  # a.k.a. `tests.testers.runCommand.bork`
  pytest-network = testers.runCommand {
    name = "bork-pytest-network";
    nativeBuildInputs = [
      bork
      cacert
      git
      pytest
    ];
    script = ''
      # Copy the source tree over, and make it writeable
      cp -r ${bork.src} bork/
      find -type d -exec chmod 0755 '{}' '+'

      pytest -v -m network bork/
      touch $out
    '';
  };
}