Unverified Commit b4368e5a authored by Sandro Jäckel's avatar Sandro Jäckel
Browse files

python312Packages.pytest-django: 4.8.0 -> 4.9.0, drop pytest-xdist due causing instability

parent e06ffb00
Loading
Loading
Loading
Loading
+7 −11
Original line number Diff line number Diff line
@@ -7,17 +7,17 @@
  setuptools-scm,
  django-configurations,
  pytest,
  pytest-xdist,
  pytestCheckHook,
}:
buildPythonPackage rec {
  pname = "pytest-django";
  version = "4.8.0";
  version = "4.9.0";
  pyproject = true;

  src = fetchPypi {
    inherit pname version;
    hash = "sha256-XQVP4BHFbzsQ+Xj0Go77Llrfx+aA7zb7VxraHyR3nZA=";
    pname = "pytest_django";
    inherit version;
    hash = "sha256-i/e8NYya5vb8UbbOuxkP4gISGW5oBxIfEb1qOwNCgxQ=";
  };

  build-system = [
@@ -31,23 +31,18 @@ buildPythonPackage rec {

  nativeCheckInputs = [
    django-configurations
    pytest-xdist
    # pytest-xidst causes random errors in the form of: django.db.utils.OperationalError: no such table: app_item
    pytestCheckHook
  ];

  preCheck = ''
    # bring pytest_django_test module into PYTHONPATH
    export PYTHONPATH="$(pwd):$PYTHONPATH"
    export PYTHONPATH="$PWD:$PYTHONPATH"

    # test the lightweight sqlite flavor
    export DJANGO_SETTINGS_MODULE="pytest_django_test.settings_sqlite"
  '';

  disabledTests = [
    # AttributeError: type object 'TestLiveServer' has no attribute '_test_settings_before_run'
    "test_settings_restored"
  ];

  __darwinAllowLocalNetworking = true;

  meta = with lib; {
@@ -55,5 +50,6 @@ buildPythonPackage rec {
    description = "Pytest plugin for testing of Django applications";
    homepage = "https://pytest-django.readthedocs.org/en/latest/";
    license = licenses.bsd3;
    maintainers = [ ];
  };
}