Skip to content

Commit

Permalink
Deleting duplicate properties and updates (#173)
Browse files Browse the repository at this point in the history
* Delete duplicate properties and update types

* Update sessions properties

* Fix tests
  • Loading branch information
armando-rodriguez-cko authored Nov 4, 2024
1 parent bd6c2ae commit d9b9695
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 10 deletions.
8 changes: 3 additions & 5 deletions checkout_sdk/accounts/accounts.py
Original file line number Diff line number Diff line change
Expand Up @@ -164,9 +164,9 @@ class OnboardSubEntityDocuments:
shareholder_structure: ShareholderStructure
proof_of_legality: ProofOfLegality
proof_of_principal_address: ProofOfPrincipalAddress
additional_document_1: AdditionalDocument
additional_document_2: AdditionalDocument
additional_document_3: AdditionalDocument
additional_document1: AdditionalDocument
additional_document2: AdditionalDocument
additional_document3: AdditionalDocument
tax_verification: TaxVerification
financial_verification: FinancialVerification

Expand Down Expand Up @@ -207,15 +207,13 @@ class Company:
business_type: BusinessType
legal_name: str
trading_name: str
business_registration_number: str
date_of_incorporation: DateOfIncorporation
regulatory_licence_number: str
principal_address: Address
registered_address: Address
representatives: list # EntityRepresentative
document: EntityDocument
financial_details: EntityFinancialDetails
business_type: BusinessType


class Identification:
Expand Down
6 changes: 3 additions & 3 deletions checkout_sdk/payments/hosted/hosted_payments.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
from datetime import datetime

from checkout_sdk.common.common import CustomerRequest
from checkout_sdk.common.common import CustomerRequest, CustomerRetry
from checkout_sdk.common.enums import Currency
from checkout_sdk.payments.payments import BillingDescriptor, PaymentType, ShippingDetails, ThreeDsRequest, \
RiskRequest, PaymentRecipient, ProcessingSettings, PaymentSender, PaymentRetryRequest
RiskRequest, PaymentRecipient, ProcessingSettings, PaymentSender
from checkout_sdk.payments.payments_previous import BillingInformation


Expand All @@ -27,7 +27,7 @@ class HostedPaymentsSessionRequest:
disabled_payment_methods: list # PaymentSourceType
products: list # common.Product
risk: RiskRequest
customer_retry: PaymentRetryRequest
customer_retry: CustomerRetry
sender: PaymentSender
success_url: str
cancel_url: str
Expand Down
15 changes: 14 additions & 1 deletion checkout_sdk/sessions/sessions.py
Original file line number Diff line number Diff line change
Expand Up @@ -250,8 +250,21 @@ def __init__(self):
super().__init__(SessionSourceType.NETWORK_TOKEN)


class ThreeDsReqAuthMethod(str, Enum):
NoThreedsRequestorAuthenticationOccurred = "no_threeds_requestor_authentication_occurred"
Three3dsRequestorOwnCredentials = "three3ds_requestor_own_credentials"
FederatedId = "federated_id"
IssuerCredentials = "issuer_credentials"
ThirdPartyAuthentication = "third_party_authentication"
FidoAuthenticator = "fido_authenticator"
FidoAuthenticatorFidoAssuranceDataSigned = "fido_authenticator_fido_assurance_data_signed"
SrcAssuranceData = "src_assurance_data"


class ThreeDsRequestorAuthenticationInfo:
pass
three_ds_req_auth_method: ThreeDsReqAuthMethod
three_ds_req_auth_timestamp: datetime
three_ds_req_auth_data: str


class CardholderAccountInfo:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ def test_request_and_get_card_session_merchant_initiated_session(oauth_api: Chec
assert_response(oauth_api.sessions.get_session_details(session_id, session_secret), 'id')


# @pytest.mark.skip(reason='unstable')
def test_request_and_get_card_session_browser_session(oauth_api: CheckoutApi):
browser_session = get_browser_session()
session_request = get_non_hosted_session(browser_session, Category.PAYMENT,
Expand Down

0 comments on commit d9b9695

Please sign in to comment.