def test_store_error_stores_ach_error(): with foo_user(): for message in ['cheese is yummy', 'cheese smells like my vibrams']: billing.store_error(u"bank account", 'foo', message) rec = gittip.db.fetchone("select * from participants " "where id='foo'") assert rec['last_ach_result'] == message
def test_store_error_stores_bill_error(): with foo_user(): billing.store_error(u"credit card", "foo", "cheese is yummy") rec = gittip.db.fetchone("select * from participants where id='foo'") expected = "cheese is yummy" actual = rec['last_bill_result'] assert actual == expected, actual
def test_store_error_stores_bill_error(self): billing.store_error(u"credit card", "alice", "cheese is yummy") rec = gittip.db.one("select * from participants where " "username='******'") expected = "cheese is yummy" actual = rec.last_bill_result assert actual == expected, actual
def test_store_error_stores_bill_error(self): billing.store_error(self.db, u"credit card", "alice", "cheese is yummy") rec = self.db.one("select * from participants where " "username='******'") expected = "cheese is yummy" actual = rec.last_bill_result assert actual == expected
def test_store_error_stores_bill_error(self): billing.store_error(u"credit card", "alice", "cheese is yummy") rec = gittip.db.fetchone("select * from participants where " "username='******'") expected = "cheese is yummy" actual = rec['last_bill_result'] assert actual == expected, actual
def test_store_error_stores_ach_error(self): for message in ['cheese is yummy', 'cheese smells like my vibrams']: billing.store_error(u"bank account", 'alice', message) rec = gittip.db.one("select * from participants " "where username='******'") assert rec.last_ach_result == message
def test_store_error_stores_ach_error(self): for message in ['cheese is yummy', 'cheese smells like my vibrams']: billing.store_error(self.db, u"bank account", 'alice', message) rec = self.db.one("select * from participants " "where username='******'") assert rec.last_ach_result == message
def test_store_ach_error(self): for message in ['cheese is yummy', 'cheese smells like my vibrams']: billing.store_error(u"bank account", self.participant_id, message) rec = self.db.fetchone("select * from participants where id=%s", (self.participant_id,)) self.assertEqual(rec['last_ach_result'], message)
def test_store_error_stores_error(self): billing.store_error(u"credit card", "lgtest", "cheese is yummy") rec = self.db.fetchone("select * from participants where id='lgtest'") self.assertEqual(rec['last_bill_result'], "cheese is yummy")
def test_store_error_stores_ach_error(self): for message in ["cheese is yummy", "cheese smells like my vibrams"]: billing.store_error("bank account", "alice", message) rec = gittip.db.one("select * from participants " "where username='******'") assert rec["last_ach_result"] == message
def test_store_ach_error(self): for message in ['cheese is yummy', 'cheese smells like my vibrams']: billing.store_error(u"bank account", self.participant_id, message) rec = self.db.fetchone("select * from participants where id=%s", (self.participant_id, )) self.assertEqual(rec['last_ach_result'], message)