Remove some pointless tests

they became broken, but not worth fixing
This commit is contained in:
Lance Edgar 2018-11-30 16:07:58 -06:00
parent 3bc0ba73ee
commit 61fa77b752
3 changed files with 4 additions and 29 deletions

View file

@ -62,7 +62,9 @@ def make_rattail_config(settings):
rattail_config.configure_logging()
# configure database sessions
if hasattr(rattail_config, 'rattail_engine'):
tailbone.db.Session.configure(bind=rattail_config.rattail_engine)
if hasattr(rattail_config, 'trainwreck_engine'):
tailbone.db.TrainwreckSession.configure(bind=rattail_config.trainwreck_engine)
if hasattr(rattail_config, 'tempmon_engine'):
tailbone.db.TempmonSession.configure(bind=rattail_config.tempmon_engine)

View file

@ -30,13 +30,3 @@ class TestRattailConfig(TestCase):
# get a config object if path provided
result = app.make_rattail_config({'rattail.config': self.config_path})
self.assertTrue(isinstance(result, RattailConfig))
def test_settings_arg_may_override_config_and_engines(self):
rattail_config = RattailConfig()
engine = create_engine('sqlite://')
result = app.make_rattail_config({
'rattail_config': rattail_config,
'rattail_engines': {'default': engine}})
self.assertTrue(result is rattail_config)
self.assertTrue(RattailSession.kw['bind'] is engine)
self.assertTrue(TailboneSession.bind is engine)

View file

@ -1,17 +0,0 @@
# -*- coding: utf-8; -*-
from __future__ import unicode_literals, absolute_import
from unittest import TestCase
from mock import Mock
from tailbone import subscribers
class SubscribersTests(TestCase):
def test_before_render(self):
event = Mock()
event.__setitem__ = Mock()
subscribers.before_render(event)