* Fixed bug in 'find_cards'.

* Seperated CSS and HTML on the cards.
This commit is contained in:
David Snopek
2013-07-26 14:09:25 +01:00
parent dbed1ef303
commit 0798415076
2 changed files with 8 additions and 6 deletions

View File

@@ -316,8 +316,9 @@ class CollectionHandlerTest(CollectionTestBase):
ret = self.execute('next_card', {})
self.assertEqual(ret['id'], card_id)
self.assertEqual(ret['nid'], note_id)
self.assertEqual(ret['question'], '<style>.card {\n font-family: arial;\n font-size: 20px;\n text-align: center;\n color: black;\n background-color: white;\n}\n</style>The front')
self.assertEqual(ret['answer'], '<style>.card {\n font-family: arial;\n font-size: 20px;\n text-align: center;\n color: black;\n background-color: white;\n}\n</style>The front\n\n<hr id=answer>\n\nThe back')
self.assertEqual(ret['css'], '<style>.card {\n font-family: arial;\n font-size: 20px;\n text-align: center;\n color: black;\n background-color: white;\n}\n</style>')
self.assertEqual(ret['question'], 'The front')
self.assertEqual(ret['answer'], 'The front\n\n<hr id=answer>\n\nThe back')
self.assertEqual(ret['answer_buttons'], [
{'ease': 1,
'label': 'Again',