Hi, im doing some unit testing. The following test works fine
def test_template_submit_functional(testapp, dbsession):
test_data = (('subject', 'Das ist ein test'),
('plain_body', dummy_text),
('form.submit', 'Speichern')
)
response = testapp.post('/config/mails/instance_removal_imminent',
params=test_data, status=302)
assert response.location == 'http://example.com/config/mails/templates'
The call should create an entry in the database.
When i try to find the object via dbsession.query() nothing is found.
I've done single step debugging and the view function is executed
correctly and all changes to the database are there.
While debugging, I found that there is a different dbsession in the request object inside the testapp call than in the test function.
Another question. Is there a way to access the session object to verify changes there.
Regards Estartu -- You received this message because you are subscribed to the Google Groups "pylons-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/pylons-discuss/7efe97b2-f786-4e2b-ad61-13ea2d6dd1a0%40augusta.de.
OpenPGP_0x3EE6A5DC78826E6B.asc
Description: OpenPGP public key
OpenPGP_signature.asc
Description: OpenPGP digital signature
