flakytest.dev anze3db fedidevs
Tests / starter_packs/tests.py

TestOwnerManagement::test_non_owner_cannot_open_manage_page

First seen 3 weeks ago in 0c23747
CI github-actions:test 11 runs
Average
125 ms
median 102 ms
max 249 ms
Phases
Setup 2 ms Call 122 ms Teardown 0.41 ms
Categories
Database 32 ms Test code 0.41 ms Other (Libraries, pytest, Unsampled, Deep copies, ...) 92 ms

23 database queries per run

Needs 288 KB of memory (max 1 MB)

Duration per run

Where the time goes

Latest run in ci:github-actions:test, 7 hours ago · open run
Show pytest frames
call115 ms98.8%
TransactionTestCase._post_teardowndjango/test/testcases.py:1243 self._fixture_teardown()88 ms75.8%
TestCase._fixture_teardowndjango/test/testcases.py:149884 ms71.9%
DatabaseWrapper.check_constraintsdjango/db/backends/postgresql/base.py:49684 ms71.9%
CursorWrapper.executedjango/db/backends/utils.py:7984 ms71.9%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:9284 ms71.9%
CursorWrapper._executedjango/db/backends/utils.py:10384 ms71.9%
Cursor.executepsycopg/cursor.py:11384 ms71.9%
Connection.waitpsycopg/connection.py:49584 ms71.9%
TestCase._fixture_teardowndjango/test/testcases.py:15004 ms3.8%
TestCase._rollback_atomicsdjango/test/testcases.py:14083 ms2.9%
Atomic.__exit__django/db/transaction.py:2982 ms1.9%
async_unsafe.<locals>.decorator.<locals>.innerdjango/utils/asyncio.py:262 ms1.9%
BaseDatabaseWrapper.savepoint_commitdjango/db/backends/base/base.py:4312 ms1.9%
BaseDatabaseWrapper._savepoint_commitdjango/db/backends/base/base.py:3752 ms1.9%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.9%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.9%
CursorWrapper._executedjango/db/backends/utils.py:1032 ms1.9%
Cursor.executepsycopg/cursor.py:1132 ms1.9%
Connection.waitpsycopg/connection.py:4952 ms1.9%
BaseCursor._execute_genpsycopg/_cursor_base.py:2061 ms1.0%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2861 ms1.0%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:781 ms1.0%
Atomic.__exit__django/db/transaction.py:2951 ms1.0%
async_unsafe.<locals>.decorator.<locals>.innerdjango/utils/asyncio.py:261 ms1.0%
BaseDatabaseWrapper.savepoint_rollbackdjango/db/backends/base/base.py:4131 ms1.0%
BaseDatabaseWrapper._savepoint_rollbackdjango/db/backends/base/base.py:3711 ms1.0%
CursorWrapper.executedjango/db/backends/utils.py:791 ms1.0%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:921 ms1.0%
CursorWrapper._executedjango/db/backends/utils.py:1031 ms1.0%
Cursor.executepsycopg/cursor.py:1131 ms1.0%
Connection.waitpsycopg/connection.py:4951 ms1.0%
TestOwnerManagement.test_non_owner_cannot_open_manage_pagestarter_packs/tests.py:462 response = self.client.get(reverse("manage_owners", args=[self.pack.slug]))21 ms18.2%
Client.getdjango/test/client.py:113321 ms18.2%
RequestFactory.getdjango/test/client.py:47521 ms18.2%
RequestFactory.genericdjango/test/client.py:67121 ms18.2%
Client.requestdjango/test/client.py:109121 ms18.2%
ClientHandler.__call__django/test/client.py:17321 ms18.2%
BaseHandler.load_middlewaredjango/core/handlers/base.py:6321 ms18.2%
__init____init__:-121 ms18.2%
WhiteNoiseMiddleware.__init__whitenoise/middleware.py:10421 ms18.2%
WhiteNoise.add_fileswhitenoise/base.py:10821 ms18.2%
WhiteNoise.update_files_dictionarywhitenoise/base.py:11513 ms11.5%
scantreewhitenoise/base.py:27110 ms8.6%
scantreewhitenoise/base.py:2716 ms4.8%
scantreewhitenoise/base.py:2692 ms1.9%
scantreewhitenoise/base.py:2712 ms1.9%
scantreewhitenoise/base.py:2712 ms1.9%
scantreewhitenoise/base.py:2712 ms1.9%
scantreewhitenoise/base.py:2691 ms1.0%
scantreewhitenoise/base.py:2731 ms1.0%
scantreewhitenoise/base.py:2731 ms1.0%
scantreewhitenoise/base.py:2734 ms3.8%
scantreewhitenoise/base.py:2692 ms1.9%
scantreewhitenoise/base.py:2731 ms1.0%
WhiteNoise.update_files_dictionarywhitenoise/base.py:1208 ms6.7%
WhiteNoise.add_file_to_dictionarywhitenoise/base.py:1318 ms6.7%
WhiteNoise.get_static_filewhitenoise/base.py:2177 ms5.8%
StaticFile.__init__whitenoise/responders.py:726 ms4.8%
StaticFile.get_file_statswhitenoise/responders.py:1616 ms4.8%
__init____init__:-16 ms4.8%
FileEntry.__init__whitenoise/responders.py:2636 ms4.8%
FileEntry.stat_regular_filewhitenoise/responders.py:2764 ms3.8%
<GC>~4 ms3.8%
StaticFile.__init__whitenoise/responders.py:771 ms1.0%
StaticFile.get_alternativeswhitenoise/responders.py:2001 ms1.0%
WhiteNoise.get_static_filewhitenoise/base.py:2121 ms1.0%
WhiteNoise.add_cache_headerswhitenoise/base.py:2331 ms1.0%
WhiteNoiseMiddleware.immutable_file_testwhitenoise/middleware.py:1761 ms1.0%
WhiteNoiseMiddleware.get_static_urlwhitenoise/middleware.py:1971 ms1.0%
TestOwnerManagement.test_non_owner_cannot_open_manage_pagestarter_packs/tests.py:461 self.client.force_login(self.friend) # not an owner3 ms2.9%
ClientMixin.force_logindjango/test/client.py:8583 ms2.9%
ClientMixin._logindjango/test/client.py:8893 ms2.9%
logindjango/contrib/auth/__init__.py:1751 ms1.0%
AbstractBaseUser.get_session_auth_hashdjango/contrib/auth/base_user.py:1361 ms1.0%
AbstractBaseUser._get_session_auth_hashdjango/contrib/auth/base_user.py:1441 ms1.0%
salted_hmacdjango/utils/crypto.py:611 ms1.0%
logindjango/contrib/auth/__init__.py:1771 ms1.0%
SessionBase.__contains__django/contrib/sessions/backends/base.py:521 ms1.0%
SessionBase._get_sessiondjango/contrib/sessions/backends/base.py:2541 ms1.0%
SessionStore.loaddjango/contrib/sessions/backends/db.py:551 ms1.0%
SessionStore._get_session_from_dbdjango/contrib/sessions/backends/db.py:341 ms1.0%
BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_methoddjango/db/models/manager.py:871 ms1.0%
QuerySet.getdjango/db/models/query.py:7021 ms1.0%
QuerySet.__len__django/db/models/query.py:4211 ms1.0%
QuerySet._fetch_alldjango/db/models/query.py:22621 ms1.0%
ModelIterable.__iter__django/db/models/query.py:1031 ms1.0%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16251 ms1.0%
CursorWrapper.executedjango/db/backends/utils.py:791 ms1.0%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:921 ms1.0%
CursorWrapper._executedjango/db/backends/utils.py:1051 ms1.0%
Cursor.executepsycopg/cursor.py:1131 ms1.0%
Connection.waitpsycopg/connection.py:4951 ms1.0%
logindjango/contrib/auth/__init__.py:1891 ms1.0%
SessionBase.cycle_keydjango/contrib/sessions/backends/base.py:4371 ms1.0%
SessionStore.createdjango/contrib/sessions/backends/db.py:741 ms1.0%
SessionStore.savedjango/contrib/sessions/backends/db.py:1261 ms1.0%
Atomic.__exit__django/db/transaction.py:2591 ms1.0%
async_unsafe.<locals>.decorator.<locals>.innerdjango/utils/asyncio.py:261 ms1.0%
BaseDatabaseWrapper.savepoint_commitdjango/db/backends/base/base.py:4311 ms1.0%
BaseDatabaseWrapper._savepoint_commitdjango/db/backends/base/base.py:3751 ms1.0%
CursorWrapper.executedjango/db/backends/utils.py:791 ms1.0%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:921 ms1.0%
CursorWrapper._executedjango/db/backends/utils.py:1031 ms1.0%
Cursor.executepsycopg/cursor.py:1131 ms1.0%
Connection.waitpsycopg/connection.py:4951 ms1.0%
BaseCursor._execute_genpsycopg/_cursor_base.py:2061 ms1.0%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2861 ms1.0%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:781 ms1.0%
TransactionTestCase._pre_setupdjango/test/testcases.py:1167 cls._fixture_setup()1 ms1.0%
Estimated from 103 samples; phase durations are exact. Frames from pytest and pluggy are hidden .

Hot lines in your code

starter_packs/tests.py:462
response = self.client.get(reverse("manage_owners", args=[self.pack.slug]))
TestOwnerManagement.test_non_owner_cannot_open_manage_page · Libraries
21 ms
starter_packs/tests.py:461
self.client.force_login(self.friend) # not an owner
TestOwnerManagement.test_non_owner_cannot_open_manage_page · Database
3 ms

Fixtures

Exact setup time
_django_db_marker function 0.08 ms
_dj_autoclear_mailbox function 0.06 ms
_template_string_if_invalid_marker function 0.06 ms
_django_isolate_apps function 0.05 ms
_live_server_helper function 0.04 ms
_django_set_urlconf function 0.04 ms
_django_clear_site_cache function 0.03 ms
monkeypatch function 0.02 ms

Database

23 queries · 22 ms
No repeated queries.

Biggest pieces of work

call _post_teardown
django/test/testcases.py:1243
88 ms
call test body
starter_packs/tests.py:462
25 ms
call _pre_setup
django/test/testcases.py:1167
1 ms
call pytest internals 1 ms

Reliability

12 results · 0 CI failures · 0 local failures

This test hasn't failed recently.

History

Latest 12 results, oldest first in the strip
When Environment Outcome Duration Commit
7 hours ago CI github-actions:test passed 117 ms c28a326 main Profile
16 hours ago CI github-actions:test passed 54 ms 9b8826a main Profile
22 hours ago CI github-actions:test passed 131 ms 4f01055 main Profile
1 week, 5 days ago CI github-actions:test passed 102 ms 8ab642e main Profile
2 weeks, 2 days ago CI github-actions:test passed 73 ms 9b75244 main Profile
2 weeks, 2 days ago CI github-actions:test passed 101 ms 9603516 main Profile
2 weeks, 4 days ago CI github-actions:test passed 91 ms 615a272 main Profile
3 weeks ago CI github-actions:test passed 81 ms d923a46 main Profile
3 weeks ago CI github-actions:test passed 249 ms 82997f8 main Profile
3 weeks ago CI github-actions:test passed 197 ms 623aa3e main Profile
3 weeks ago CI github-actions:test passed 176 ms ab6465a main Profile
3 weeks ago CI github-actions:test passed 77 ms 0c23747 main Run