"""conftest.""" from pytest import fixture @fixture def mock_event(): """Mock abacus event.""" return { 'abacus_event_id': 1, 'target_type': 'statement_period_adjustment_file', 'target_id': '1', 'event_name': 'generate_flowthrough_adjustments', 'event_date': '2026-02-13T11:20:35.45+01:00', 'statement_period_id': 1, } @fixture def mock_statement_period(): """Mock statement period.""" return { 'statement_period_id': 325, 'statement_period_name': 'January 2026', 'statement_period_status': 'current', 'statement_month': 1, 'statement_year': 2026, 'closed_date': None, 'exchange_rates_delivered': None, } @fixture def mock_statement_period_adjustment_file(): """Mock statement period adjustment file.""" return { 'file_name': 'flowthrough_adjustments_file', 'valid_file_location': 's3://test/5011/dcc6ef7f-eace-4fdf-9403-fb305914371f.xlsx', 'invalid_file_location': None, 'valid_row_count': 3, 'invalid_row_count': 0, 'total_file_amount_multicurrency': '-211.000000000000', 'total_rounded_amount_multicurrency': '-211.00', 'md5sum': None, 'error_type': None, 'source_file_upload_id': None, 'statement_period_adjustment_file_id': 1, 'statement_period_id': 1, } @fixture def mock_statement_period_adjustment_batch_criteria(): """Mock statement period adjustment batch criteria.""" return { 'batch_criteria': { 'reference_payment_entities': [1, 2, 3, 4], 'payment_schedules': [ '30_days_after_month_end', '45_days_after_month_end', '60_days_after_month_end', ], }, 'statement_period_adjustment_file_id': 1, 'statement_period_adjustment_batch_criteria_id': 1, } @fixture def mock_flowthrough_adjustments(): """Mock flowthrough adjustments.""" return [ { 'Account Name': 'IN REAL LIFE MUSIC LLC', 'Account ID': 56158, 'Contract Name': 'AGR544584 - AWAL Recordings Agreement - Various', 'Contract ID': 531600, 'UPC': '', 'Amount': '-5424.04', 'Currency': 'USD', 'Activity Month': 1, 'Activity Year': 2026, 'Statement Month': 1, 'Statement Year': 2026, 'Adjustment Type': 'Flowthrough', 'Client Facing Comments': 'July 2024: 42% Flowthrough of net revenue to AGR547783 - Paythrough Agreement - 532162', 'Distribution Type': '', 'Internal Note': '', 'Apply to Flowthrough Payment': 'Y', } ]