edx_django_utils.monitoring.tests package#
Subpackages#
Submodules#
edx_django_utils.monitoring.tests.test_custom_monitoring module#
Tests for CachedCustomMonitoringMiddleware and associated utilities.
Note: See test_middleware.py for the rest of the middleware tests.
- class edx_django_utils.monitoring.tests.test_custom_monitoring.TestCustomMonitoringMiddleware(methodName='runTest')#
Bases:
django.test.testcases.TestCase
Test the monitoring_utils middleware and helpers
- setUp()#
Hook method for setting up the test fixture before exercising it.
- test_accumulate_and_increment_1(cached_monitoring_middleware_class, is_deprecated, middleware_method_name, mock_newrelic_agent)#
Test normal usage of collecting custom attributes and reporting to New Relic
- test_accumulate_and_increment_2(cached_monitoring_middleware_class, is_deprecated, middleware_method_name, mock_newrelic_agent)#
Test normal usage of collecting custom attributes and reporting to New Relic
- test_accumulate_and_increment_3(cached_monitoring_middleware_class, is_deprecated, middleware_method_name, mock_newrelic_agent)#
Test normal usage of collecting custom attributes and reporting to New Relic
- test_accumulate_and_increment_4(cached_monitoring_middleware_class, is_deprecated, middleware_method_name, mock_newrelic_agent)#
Test normal usage of collecting custom attributes and reporting to New Relic
- test_accumulate_with_illegal_value_1(cached_monitoring_middleware_class, is_deprecated, mock_newrelic_agent)#
Test monitoring accumulate with illegal value that can’t be added.
- test_accumulate_with_illegal_value_2(cached_monitoring_middleware_class, is_deprecated, mock_newrelic_agent)#
Test monitoring accumulate with illegal value that can’t be added.
- test_accumulate_with_illegal_value_3(cached_monitoring_middleware_class, is_deprecated, mock_newrelic_agent)#
Test monitoring accumulate with illegal value that can’t be added.
- test_deprecated_accumulate(mock_accumulate)#
- test_deprecated_increment(mock_increment)#
- test_deprecated_set_custom_attribute(mock_set_custom_attribute)#
- test_deprecated_set_custom_attributes_for_course_key(mock_set_custom_attributes_for_course_key)#
- test_get_current_transaction(mock_newrelic_agent)#
- test_get_current_transaction_without_newrelic()#
- test_record_exception(mock_record_exception)#
edx_django_utils.monitoring.tests.test_middleware module#
edx_django_utils.monitoring.tests.test_utils module#
Tests for utilities in monitoring.
- edx_django_utils.monitoring.tests.test_utils.test_background_task_wrapper(wrapped_nr)#
- edx_django_utils.monitoring.tests.test_utils.test_background_task_wrapper_no_new_relic()#