File: common.py

package info (click to toggle)
odoo 18.0.0%2Bdfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 878,716 kB
  • sloc: javascript: 927,937; python: 685,670; xml: 388,524; sh: 1,033; sql: 415; makefile: 26
file content (43 lines) | stat: -rw-r--r-- 1,528 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
# Part of Odoo. See LICENSE file for full copyright and licensing details.

from odoo.addons.payment.tests.http_common import PaymentHttpCommon


class APSCommon(PaymentHttpCommon):

    @classmethod
    def setUpClass(cls):
        super().setUpClass()

        cls.aps = cls._prepare_provider('aps', update_values={
            'aps_merchant_identifier': '123456abc',
            'aps_access_code': 'dummy',
            'aps_sha_request': 'dummy',
            'aps_sha_response': 'dummy',
        })

        cls.provider = cls.aps

        cls.notification_data = {
            'access_code': cls.provider.aps_access_code,
            'amount': cls.amount,
            'authorization_code': '123456',
            'card_holder_name': 'Mitchell',
            'card_number': '************1111',
            'command': 'PURCHASE',
            'currency': 'USD',
            'customer_email': '	admin@yourcompany.example.com',
            'customer_ip': '123.456.78.90',
            'eci': 'ECOMMERCE',
            'expiry_date': '2212',
            'fort_id': '169996210006464984',
            'language': 'en',
            'merchant_identifier': cls.provider.aps_merchant_identifier,
            'merchant_reference': cls.reference,
            'payment_option': 'VISA',
            'response_code': '14000',
            'response_message': 'Success',
            'signature': '6d2bb7904ac6141a0c10375c70fd417616c740bb1ddab862a224777880aa3600',
            'status': '14',
            'token_name': '123abc456def789',
        }