Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@


class TestOfflinePaymentMethod(IntegrationTestCase):
def setUp(self):
# Clean up any leftover Offline Payment Method records from previous tests
frappe.db.delete("Offline Payment Method")

def test_unique_title_per_event(self):
"""Test that two methods with the same title cannot exist for the same event."""
test_event = frappe.get_doc("Buzz Event", {"route": "test-route"})
Expand Down
5 changes: 5 additions & 0 deletions buzz/ticketing/doctype/event_booking/test_event_booking.py
Original file line number Diff line number Diff line change
Expand Up @@ -823,6 +823,7 @@ def test_process_booking_offline_stays_in_draft(self):

test_event = frappe.get_doc("Buzz Event", {"route": "test-route"})
test_event.apply_tax = False
test_event.is_published = True
test_event.save()
self._cleanup_offline_methods(test_event.name)

Expand Down Expand Up @@ -879,6 +880,7 @@ def test_process_booking_offline_generates_tickets_on_approval(self):

test_event = frappe.get_doc("Buzz Event", {"route": "test-route"})
test_event.apply_tax = False
test_event.is_published = True
test_event.save()
self._cleanup_offline_methods(test_event.name)

Expand Down Expand Up @@ -938,6 +940,8 @@ def test_process_booking_without_utm_parameters(self):
from buzz.api import process_booking

test_event = frappe.get_doc("Buzz Event", {"route": "test-route"})
test_event.is_published = True
test_event.save()

test_ticket_type = frappe.get_doc(
{
Expand Down Expand Up @@ -991,6 +995,7 @@ def test_process_booking_with_empty_utm_parameters(self):

# Disable tax at event level
test_event.apply_tax = False
test_event.is_published = True
test_event.save()

attendees = [
Expand Down
2 changes: 2 additions & 0 deletions buzz/ticketing/doctype/event_booking/test_guest_booking.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ def setUp(self):
self.original_verification = self.test_event.guest_verification_method
self.test_event.allow_guest_booking = True
self.test_event.guest_verification_method = "None"
self.test_event.is_published = True
self.test_event.save()
self.ticket_type = str(self._get_or_create_free_ticket_type())

Expand All @@ -28,6 +29,7 @@ def tearDown(self):
self.test_event.reload()
self.test_event.allow_guest_booking = self.original_allow_guest
self.test_event.guest_verification_method = self.original_verification
self.test_event.is_published = False
self.test_event.save()

# --- helpers ---
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# Ticket Email Notification
Loading