oioioi.oi.tests

Module Contents

Classes

TestOIAdmin

Similar to TransactionTestCase, but use transaction.atomic() to achieve

TestOIRegistration

Similar to TransactionTestCase, but use transaction.atomic() to achieve

TestOIViews

Similar to TransactionTestCase, but use transaction.atomic() to achieve

TestSchoolAdding

Similar to TransactionTestCase, but use transaction.atomic() to achieve

TestSchoolAdmin

Similar to TransactionTestCase, but use transaction.atomic() to achieve

TestSchoolMerging

Similar to TransactionTestCase, but use transaction.atomic() to achieve

TestOISubmit

Similar to TransactionTestCase, but use transaction.atomic() to achieve

TestOIOnsiteSubmit

Similar to TransactionTestCase, but use transaction.atomic() to achieve

TestIgnoringCE

Similar to TransactionTestCase, but use transaction.atomic() to achieve

TestUserInfo

Similar to TransactionTestCase, but use transaction.atomic() to achieve

class oioioi.oi.tests.TestOIAdmin(methodName='runTest')[source]

Bases: oioioi.base.tests.TestCase

Similar to TransactionTestCase, but use transaction.atomic() to achieve test isolation.

In most situations, TestCase should be preferred to TransactionTestCase as it allows faster execution. However, there are some situations where using TransactionTestCase might be necessary (e.g. testing some transactional behavior).

On database backends with no transaction support, TestCase behaves as TransactionTestCase.

fixtures = ['test_users', 'test_contest', 'test_oi_registration', 'test_permissions'][source]
test_admin_menu()[source]
test_schools_import()[source]
test_safe_exec_mode()[source]
test_terms_accepted_phrase_inline_admin_permissions()[source]
test_terms_accepted_phrase_inline_edit_restrictions()[source]
class oioioi.oi.tests.TestOIRegistration(methodName='runTest')[source]

Bases: oioioi.base.tests.TestCase

Similar to TransactionTestCase, but use transaction.atomic() to achieve test isolation.

In most situations, TestCase should be preferred to TransactionTestCase as it allows faster execution. However, there are some situations where using TransactionTestCase might be necessary (e.g. testing some transactional behavior).

On database backends with no transaction support, TestCase behaves as TransactionTestCase.

fixtures = ['test_users', 'test_contest', 'test_schools', 'test_terms_accepted_phrase'][source]
setUp()[source]

Hook method for setting up the test fixture before exercising it.

test_participants_accounts_menu()[source]
test_participants_unregister_forbidden()[source]
test_default_terms_accepted_phrase()[source]
test_participants_registration()[source]
test_registration_with_new_school()[source]
class oioioi.oi.tests.TestOIViews(methodName='runTest')[source]

Bases: oioioi.base.tests.TestCase

Similar to TransactionTestCase, but use transaction.atomic() to achieve test isolation.

In most situations, TestCase should be preferred to TransactionTestCase as it allows faster execution. However, there are some situations where using TransactionTestCase might be necessary (e.g. testing some transactional behavior).

On database backends with no transaction support, TestCase behaves as TransactionTestCase.

fixtures = ['test_users', 'test_contest', 'test_full_package', 'test_problem_instance', 'test_submission'][source]
test_contest_visibility()[source]
test_contest_access()[source]
test_ranking_access()[source]
class oioioi.oi.tests.TestSchoolAdding(methodName='runTest')[source]

Bases: oioioi.base.tests.TestCase

Similar to TransactionTestCase, but use transaction.atomic() to achieve test isolation.

In most situations, TestCase should be preferred to TransactionTestCase as it allows faster execution. However, there are some situations where using TransactionTestCase might be necessary (e.g. testing some transactional behavior).

On database backends with no transaction support, TestCase behaves as TransactionTestCase.

fixtures = ['test_users', 'test_contest', 'test_schools'][source]
setUp()[source]

Hook method for setting up the test fixture before exercising it.

test_schools_similar_view()[source]
class oioioi.oi.tests.TestSchoolAdmin(methodName='runTest')[source]

Bases: oioioi.base.tests.TestCase

Similar to TransactionTestCase, but use transaction.atomic() to achieve test isolation.

In most situations, TestCase should be preferred to TransactionTestCase as it allows faster execution. However, there are some situations where using TransactionTestCase might be necessary (e.g. testing some transactional behavior).

On database backends with no transaction support, TestCase behaves as TransactionTestCase.

fixtures = ['test_users', 'test_contest', 'test_schools'][source]
test_schools_similar_finding()[source]
class oioioi.oi.tests.TestSchoolMerging(methodName='runTest')[source]

Bases: oioioi.base.tests.TestCase

Similar to TransactionTestCase, but use transaction.atomic() to achieve test isolation.

In most situations, TestCase should be preferred to TransactionTestCase as it allows faster execution. However, there are some situations where using TransactionTestCase might be necessary (e.g. testing some transactional behavior).

On database backends with no transaction support, TestCase behaves as TransactionTestCase.

fixtures = ['test_users', 'test_contest', 'test_schools'][source]
_call_admin_merge_action(schools_pk_list)[source]
test_schools_merging_unsuccessfull()[source]
class oioioi.oi.tests.TestOISubmit(methodName='runTest')[source]

Bases: oioioi.base.tests.TestCase, oioioi.programs.tests.SubmitFileMixin

Similar to TransactionTestCase, but use transaction.atomic() to achieve test isolation.

In most situations, TestCase should be preferred to TransactionTestCase as it allows faster execution. However, there are some situations where using TransactionTestCase might be necessary (e.g. testing some transactional behavior).

On database backends with no transaction support, TestCase behaves as TransactionTestCase.

fixtures = ['test_users', 'test_contest', 'test_full_package', 'test_problem_instance'][source]
setUp()[source]

Hook method for setting up the test fixture before exercising it.

test_submit_permissions()[source]
class oioioi.oi.tests.TestOIOnsiteSubmit(methodName='runTest')[source]

Bases: oioioi.base.tests.TestCase, oioioi.programs.tests.SubmitFileMixin

Similar to TransactionTestCase, but use transaction.atomic() to achieve test isolation.

In most situations, TestCase should be preferred to TransactionTestCase as it allows faster execution. However, there are some situations where using TransactionTestCase might be necessary (e.g. testing some transactional behavior).

On database backends with no transaction support, TestCase behaves as TransactionTestCase.

fixtures = ['test_users', 'test_contest', 'test_full_package', 'test_problem_instance'][source]
setUp()[source]

Hook method for setting up the test fixture before exercising it.

test_submit_permissions()[source]
class oioioi.oi.tests.TestIgnoringCE(methodName='runTest')[source]

Bases: oioioi.base.tests.TestCase

Similar to TransactionTestCase, but use transaction.atomic() to achieve test isolation.

In most situations, TestCase should be preferred to TransactionTestCase as it allows faster execution. However, there are some situations where using TransactionTestCase might be necessary (e.g. testing some transactional behavior).

On database backends with no transaction support, TestCase behaves as TransactionTestCase.

fixtures = ['test_users', 'test_contest', 'test_full_package', 'test_problem_instance', 'test_submission',...[source]
_test(controller_name)[source]
test_all_oi_style_contests()[source]
class oioioi.oi.tests.TestUserInfo(methodName='runTest')[source]

Bases: oioioi.base.tests.TestCase

Similar to TransactionTestCase, but use transaction.atomic() to achieve test isolation.

In most situations, TestCase should be preferred to TransactionTestCase as it allows faster execution. However, there are some situations where using TransactionTestCase might be necessary (e.g. testing some transactional behavior).

On database backends with no transaction support, TestCase behaves as TransactionTestCase.

fixtures = ['test_users', 'test_contest', 'test_schools', 'test_permissions'][source]
test_user_info_page()[source]