2023-07-12 12:09:44 -04:00
|
|
|
import pytest
|
|
|
|
|
|
|
|
|
|
from app.models.organization import Organization
|
|
|
|
|
from tests import organization_json
|
|
|
|
|
|
|
|
|
|
|
2023-08-25 09:12:23 -07:00
|
|
|
@pytest.mark.parametrize(
|
2023-09-08 17:58:06 -04:00
|
|
|
("purchase_order_number", "expected_result"),
|
|
|
|
|
[(None, None), ("PO1234", [None, None, None, "PO1234"])],
|
2023-08-25 09:12:23 -07:00
|
|
|
)
|
2023-07-12 12:09:44 -04:00
|
|
|
def test_organization_billing_details(purchase_order_number, expected_result):
|
2023-08-25 09:12:23 -07:00
|
|
|
organization = Organization(
|
|
|
|
|
organization_json(purchase_order_number=purchase_order_number)
|
|
|
|
|
)
|
2023-07-12 12:09:44 -04:00
|
|
|
assert organization.billing_details == expected_result
|