project/scipycon/registration/tests.py
author Madhusudan.C.S <madhusudancs@gmail.com>
Tue, 13 Jul 2010 17:59:47 +0530
changeset 94 87e77aa18610
permissions -rw-r--r--
Moved the files to new Django app named scipycon and modified settings.



def test_save_to_pdf():
    """
    >>> from .pdf import save_invoice
    >>> from django.db.models.loading import get_model
    >>> userModel =  get_model('auth', 'user')
    >>> user = userModel(username='joe', email='joe@gmail.com',
    ...         first_name='Joe', last_name='Bloggs')
    >>> user.save()
    >>> regModel =  get_model('registration', 'registration')
    >>> registration = regModel(registrant=user, amount=40,
    ...          slug='NZPYCON-0001')
    >>> registration.save()

    >>> save_invoice(user, registration, 'registration/invoice.html')

    """
    pass