Unverified Commit 0fa536d5 authored by Emily's avatar Emily Committed by natsukium
Browse files

svtplay-dl: migrate to pytest

parent 4094f03f
Loading
Loading
Loading
Loading
+7 −16
Original line number Diff line number Diff line
@@ -5,7 +5,6 @@
  python3Packages,
  perl,
  ffmpeg,
  gitMinimal,
}:

let
@@ -17,8 +16,7 @@ let
    pysocks
    cryptography
    pyyaml
    nose3
    pytest
    pytestCheckHook
    mock
    requests-mock
    ;
@@ -55,27 +53,20 @@ buildPythonApplication {
  ];

  nativeCheckInputs = [
    nose3
    pytest
    pytestCheckHook
    mock
    requests-mock
    gitMinimal
  ];

  pytestFlagsArray = [
    "--doctest-modules"
    "lib"
  ];

  postBuild = ''
    make svtplay-dl.1
  '';

  doCheck = python3Packages.pythonOlder "3.12";

  checkPhase = ''
    runHook preCheck

    nosetests --all-modules --with-doctest

    runHook postCheck
  '';

  postInstall = ''
    installManPage svtplay-dl.1
    makeWrapperArgs+=(--prefix PATH : "${lib.makeBinPath [ ffmpeg ]}")