Fixed #108 -- Removed the restrictions system

This commit is contained in:
Raphael Michel
2015-12-06 17:49:02 +01:00
parent b26eaaa6c9
commit 4a1122a862
25 changed files with 26 additions and 1256 deletions

View File

@@ -4,7 +4,7 @@ from django.utils.timezone import now
from pretix.base.models import Event, Organizer
from pretix.base.plugins import get_all_plugins
from pretix.base.signals import determine_availability
from pretix.base.signals import register_ticket_outputs
class PluginRegistryTest(TestCase):
@@ -45,13 +45,13 @@ class PluginSignalTest(TestCase):
def test_no_plugins_active(self):
self.event.plugins = ''
self.event.save()
responses = determine_availability.send(self.event)
responses = register_ticket_outputs.send(self.event)
self.assertEqual(len(responses), 0)
def test_one_plugin_active(self):
self.event.plugins = 'tests.testdummy'
self.event.save()
payload = {'foo': 'bar'}
responses = determine_availability.send(self.event, **payload)
responses = register_ticket_outputs.send(self.event, **payload)
self.assertEqual(len(responses), 1)
self.assertIn('tests.testdummy.signals', [r[0].__module__ for r in responses])