setup_wizard.tests.test_views.test_setupwizardhsmsetupview¶
Tests for the SetupWizardHsmSetupView.
Classes¶
Similar to TransactionTestCase, but use transaction.atomic() to achieve |
Module Contents¶
- class setup_wizard.tests.test_views.test_setupwizardhsmsetupview.SetupWizardHsmSetupViewTestCase(methodName='runTest')[source]¶
Bases:
django.test.TestCaseSimilar 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.
- test_post_request_valid_data(mock_dispatch)[source]¶
Test that a POST request with valid data processes successfully.
- test_post_request_invalid_hsm_type(mock_dispatch)[source]¶
Test that a POST request with an unsupported HSM type shows an error.