at master 6.1 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 poetry-core, 6 django, 7 stripe, 8 mysqlclient, 9 psycopg2, 10 pytest-django, 11 pytestCheckHook, 12}: 13 14buildPythonPackage rec { 15 pname = "dj-stripe"; 16 version = "2.9.0"; 17 pyproject = true; 18 19 src = fetchFromGitHub { 20 owner = "dj-stripe"; 21 repo = "dj-stripe"; 22 tag = version; 23 hash = "sha256-ijTzSid5B79mAi7qUFSGL5+4PfmBStDWayzjW1iwRww="; 24 }; 25 26 build-system = [ poetry-core ]; 27 28 dependencies = [ 29 django 30 stripe 31 ]; 32 33 passthru.optional-dependencies = { 34 mysql = [ mysqlclient ]; 35 postgres = [ psycopg2 ]; 36 }; 37 38 env = { 39 DJANGO_SETTINGS_MODULE = "tests.settings"; 40 DJSTRIPE_TEST_DB_VENDOR = "sqlite"; 41 }; 42 43 nativeCheckInputs = [ 44 pytest-django 45 pytestCheckHook 46 ]; 47 48 disabledTestPaths = [ 49 "tests/test_customer.py::TestCustomer::test_customer_sync_unsupported_source" 50 "tests/test_customer.py::TestCustomer::test_upcoming_invoice_plan" 51 "tests/test_customer.py::TestCustomerLegacy::test_upcoming_invoice" 52 "tests/test_event_handlers.py::TestCustomerEvents::test_customer_default_source_deleted" 53 "tests/test_event_handlers.py::TestCustomerEvents::test_customer_deleted" 54 "tests/test_event_handlers.py::TestCustomerEvents::test_customer_source_double_delete" 55 "tests/test_event_handlers.py::TestPlanEvents::test_plan_created" 56 "tests/test_event_handlers.py::TestPlanEvents::test_plan_deleted" 57 "tests/test_event_handlers.py::TestPlanEvents::test_plan_updated_request_object" 58 "tests/test_event_handlers.py::TestTaxIdEvents::test_tax_id_created" 59 "tests/test_event_handlers.py::TestTaxIdEvents::test_tax_id_deleted" 60 "tests/test_event_handlers.py::TestTaxIdEvents::test_tax_id_updated" 61 "tests/test_invoice.py::InvoiceTest::test_upcoming_invoice" 62 "tests/test_invoice.py::InvoiceTest::test_upcoming_invoice_with_subscription" 63 "tests/test_invoice.py::InvoiceTest::test_upcoming_invoice_with_subscription_plan" 64 "tests/test_invoice.py::TestInvoiceDecimal::test_decimal_tax_percent" 65 "tests/test_plan.py::PlanCreateTest::test_create_from_djstripe_product" 66 "tests/test_plan.py::PlanCreateTest::test_create_from_product_id" 67 "tests/test_plan.py::PlanCreateTest::test_create_from_stripe_product" 68 "tests/test_plan.py::PlanCreateTest::test_create_with_metadata" 69 "tests/test_price.py::PriceCreateTest::test_create_from_djstripe_product" 70 "tests/test_price.py::PriceCreateTest::test_create_from_product_id" 71 "tests/test_price.py::PriceCreateTest::test_create_from_stripe_product" 72 "tests/test_price.py::PriceCreateTest::test_create_with_metadata" 73 "tests/test_settings.py::TestSubscriberModelRetrievalMethod::test_bad_callback" 74 "tests/test_settings.py::TestSubscriberModelRetrievalMethod::test_no_callback" 75 "tests/test_settings.py::TestStripeApiVersion::test_global_stripe_api_version" 76 "tests/test_subscription.py::TestSubscriptionDecimal::test_decimal_application_fee_percent" 77 "tests/test_tax_id.py::TestTaxIdStr::test___str__" 78 "tests/test_tax_id.py::TestTransfer::test__api_create" 79 "tests/test_tax_id.py::TestTransfer::test__api_create_no_customer" 80 "tests/test_tax_id.py::TestTransfer::test__api_create_no_id_kwarg" 81 "tests/test_tax_id.py::TestTransfer::test_api_list" 82 "tests/test_tax_id.py::TestTransfer::test_api_retrieve" 83 "tests/test_tax_rates.py::TestTaxRateDecimal::test_decimal_tax_percent" 84 "tests/test_transfer_reversal.py::TestTransfer::test_api_list" 85 "tests/test_transfer_reversal.py::TestTransfer::test_api_retrieve" 86 "tests/test_usage_record.py::TestUsageRecord::test___str__" 87 "tests/test_usage_record.py::TestUsageRecord::test__api_create" 88 "tests/test_usage_record_summary.py::TestUsageRecordSummary::test___str__" 89 "tests/test_usage_record_summary.py::TestUsageRecordSummary::test_api_list" 90 "tests/test_usage_record_summary.py::TestUsageRecordSummary::test_sync_from_stripe_data" 91 "tests/test_views.py::TestConfirmCustomActionView::test__cancel_subscription_instances_stripe_invalid_request_error" 92 "tests/test_views.py::TestConfirmCustomActionView::test__release_subscription_schedule_stripe_invalid_request_error" 93 "tests/test_views.py::TestConfirmCustomActionView::test__cancel_subscription_schedule_stripe_invalid_request_error" 94 "tests/test_webhooks.py::TestWebhookEventTrigger::test___str__" 95 "tests/test_webhooks.py::TestWebhookEventTrigger::test_webhook_error" 96 "tests/test_webhooks.py::TestWebhookEventTrigger::test_webhook_good_connect_account" 97 "tests/test_webhooks.py::TestWebhookEventTrigger::test_webhook_good_platform_account" 98 "tests/test_webhooks.py::TestWebhookEventTrigger::test_webhook_invalid_verify_signature_fail" 99 "tests/test_webhooks.py::TestWebhookEventTrigger::test_webhook_no_signature" 100 "tests/test_webhooks.py::TestWebhookEventTrigger::test_webhook_no_validation_pass" 101 "tests/test_webhooks.py::TestWebhookEventTrigger::test_webhook_remote_addr_is_empty_string" 102 "tests/test_webhooks.py::TestWebhookEventTrigger::test_webhook_remote_addr_is_none" 103 "tests/test_webhooks.py::TestWebhookEventTrigger::test_webhook_reraise_exception" 104 "tests/test_webhooks.py::TestWebhookEventTrigger::test_webhook_retrieve_event_fail" 105 "tests/test_webhooks.py::TestWebhookEventTrigger::test_webhook_retrieve_event_pass" 106 "tests/test_webhooks.py::TestWebhookEventTrigger::test_webhook_test_event" 107 "tests/test_webhooks.py::TestWebhookEventTrigger::test_webhook_verify_signature_pass" 108 "tests/test_webhooks.py::TestWebhookEventTrigger::test_webhook_with_custom_callback" 109 "tests/test_webhooks.py::TestWebhookEventTrigger::test_webhook_with_transfer_event_duplicate" 110 "tests/test_webhooks.py::TestGetRemoteIp::test_get_remote_ip_remote_addr_is_none" 111 ]; 112 113 pythonImportsCheck = [ "djstripe" ]; 114 115 meta = { 116 description = "Stripe Models for Django"; 117 homepage = "https://github.com/dj-stripe/dj-stripe"; 118 changelog = "https://github.com/dj-stripe/dj-stripe/releases/tag/${version}"; 119 license = lib.licenses.mit; 120 maintainers = with lib.maintainers; [ defelo ]; 121 }; 122}