Tests / confs/tests.py
TestCreateConference::test_submit_creates_pending_conference
First seen 1 month, 1 week ago in 0c23747
CI
github-actions:test
13 runs
Average
705 ms
median 652 ms
max 1.28 s
max 1.28 s
Phases
Setup 2 ms
Call 699 ms
Teardown 4 ms
Categories
Password hashing 573 ms
Database 33 ms
App code 0.08 ms
Other (Libraries, Deep copies, pytest, Unsampled, ...) 99 ms
28 database queries per run
Needs 3 KB of memory (max 12 KB)
Duration per run
Where the time goes
Latest run in ci:github-actions:test, 2 weeks ago ·
open run
call526 ms99.6%
TestCreateConference.setUpconfs/tests.py:1044 self.user = User.objects.create_user("alice", password="pw")435 ms82.4%
UserManager.create_userdjango/contrib/auth/models.py:180435 ms82.4%
UserManager._create_userdjango/contrib/auth/models.py:167434 ms82.2%
UserManager._create_user_objectdjango/contrib/auth/models.py:160434 ms82.2%
make_passworddjango/contrib/auth/hashers.py:118434 ms82.2%
PBKDF2PasswordHasher.encodedjango/contrib/auth/hashers.py:333434 ms82.2%
pbkdf2django/utils/crypto.py:93434 ms82.2%
1 smaller frames hidden
TestCreateConference.test_submit_creates_pending_conferenceconfs/tests.py:1079 response = self.client.post(reverse("create_conference"), self.form_data)64 ms12.1%
Client.postdjango/test/client.py:116264 ms12.1%
RequestFactory.postdjango/test/client.py:49964 ms12.1%
RequestFactory.genericdjango/test/client.py:67164 ms12.1%
Client.requestdjango/test/client.py:109164 ms12.1%
ClientHandler.__call__django/test/client.py:17364 ms12.1%
BaseHandler.load_middlewaredjango/core/handlers/base.py:6364 ms12.1%
WhiteNoiseMiddleware.__init__whitenoise/middleware.py:10464 ms12.1%
WhiteNoise.add_fileswhitenoise/base.py:10864 ms12.1%
WhiteNoise.update_files_dictionarywhitenoise/base.py:12056 ms10.5%
WhiteNoise.add_file_to_dictionarywhitenoise/base.py:13156 ms10.5%
WhiteNoise.get_static_filewhitenoise/base.py:21728 ms5.3%
StaticFile.__init__whitenoise/responders.py:7713 ms2.4%
StaticFile.get_alternativeswhitenoise/responders.py:2003 ms0.6%
__init____init__:-13 ms0.6%
StaticFile.get_alternativeswhitenoise/responders.py:2033 ms0.6%
StaticFile.get_alternativeswhitenoise/responders.py:2013 ms0.6%
StaticFile.__init__whitenoise/responders.py:765 ms1.0%
StaticFile.get_not_modified_responsewhitenoise/responders.py:1884 ms0.8%
Headers.__contains__<stdlib>/wsgiref/headers.py:874 ms0.8%
Headers.get<stdlib>/wsgiref/headers.py:1044 ms0.8%
1 smaller frames hidden
StaticFile.__init__whitenoise/responders.py:735 ms1.0%
StaticFile.get_headerswhitenoise/responders.py:1763 ms0.6%
2 smaller frames hidden
StaticFile.__init__whitenoise/responders.py:723 ms0.6%
1 smaller frames hidden
WhiteNoise.get_static_filewhitenoise/base.py:21227 ms5.1%
WhiteNoise.add_cache_headerswhitenoise/base.py:23327 ms5.1%
WhiteNoiseMiddleware.immutable_file_testwhitenoise/middleware.py:17626 ms4.9%
WhiteNoiseMiddleware.get_static_urlwhitenoise/middleware.py:19726 ms4.9%
URLMixin.urldebug_toolbar/panels/staticfiles.py:2021 ms4.0%
HashedFilesMixin.urldjango/contrib/staticfiles/storage.py:23521 ms4.0%
HashedFilesMixin._urldjango/contrib/staticfiles/storage.py:20818 ms3.4%
urlsplit<stdlib>/urllib/parse.py:58218 ms3.4%
_urlsplit<stdlib>/urllib/parse.py:61318 ms3.4%
HashedFilesMixin._urldjango/contrib/staticfiles/storage.py:2163 ms0.6%
1 smaller frames hidden
WhiteNoise.update_files_dictionarywhitenoise/base.py:1157 ms1.4%
scantreewhitenoise/base.py:2717 ms1.4%
scantreewhitenoise/base.py:2717 ms1.4%
scantreewhitenoise/base.py:2735 ms1.0%
1 smaller frames hidden
1 smaller frames hidden
TestCreateConference.test_submit_creates_pending_conferenceconfs/tests.py:1081 conference = Conference.objects.get(name="PyCon Test")10 ms1.8%
BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_methoddjango/db/models/manager.py:8710 ms1.8%
QuerySet.getdjango/db/models/query.py:70210 ms1.8%
QuerySet.__len__django/db/models/query.py:42110 ms1.8%
QuerySet._fetch_alldjango/db/models/query.py:226210 ms1.8%
ModelIterable.__iter__django/db/models/query.py:10310 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16259 ms1.6%
CursorWrapper.executedjango/db/backends/utils.py:799 ms1.6%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:929 ms1.6%
CursorWrapper._executedjango/db/backends/utils.py:1059 ms1.6%
Cursor.executepsycopg/cursor.py:1139 ms1.6%
Connection.waitpsycopg/connection.py:4959 ms1.6%
BaseCursor._execute_genpsycopg/_cursor_base.py:2066 ms1.2%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2866 ms1.2%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:786 ms1.2%
1 smaller frames hidden
TestCreateConference.test_submit_creates_pending_conferenceconfs/tests.py:1074 self.client.force_login(self.user)7 ms1.4%
ClientMixin.force_logindjango/test/client.py:8587 ms1.4%
ClientMixin._logindjango/test/client.py:8894 ms0.8%
logindjango/contrib/auth/__init__.py:1893 ms0.6%
1 smaller frames hidden
2 smaller frames hidden
TestCreateConference.test_submit_creates_pending_conferenceconfs/tests.py:1076 mock.patch("confs.views.send_mail") as send_mail_mock,4 ms0.8%
TransactionTestCase._post_teardowndjango/test/testcases.py:1243 self._fixture_teardown()3 ms0.6%
2 smaller frames hidden
teardown2 ms0.3%
Estimated from 493 samples; phase durations are exact. Frames from pytest and pluggy are
hidden
.
Hot lines in your code
|
confs/tests.py:1044
self.user = User.objects.create_user("alice", password="pw")
TestCreateConference.setUp
· Password hashing
|
435 ms |
|
confs/tests.py:1079
response = self.client.post(reverse("create_conference"), self.form_data)
TestCreateConference.test_submit_creates_pending_conference
· Libraries
|
64 ms |
|
confs/tests.py:1081
conference = Conference.objects.get(name="PyCon Test")
TestCreateConference.test_submit_creates_pending_conference
· Database
|
10 ms |
|
confs/tests.py:1074
self.client.force_login(self.user)
TestCreateConference.test_submit_creates_pending_conference
· Database
|
7 ms |
|
confs/tests.py:1076
mock.patch("confs.views.send_mail") as send_mail_mock,
TestCreateConference.test_submit_creates_pending_conference
· Mocking
|
4 ms |
|
confs/tests.py:1083
self.assertEqual(conference.created_by, self.user)
TestCreateConference.test_submit_creates_pending_conference
· Database
|
1 ms |
Fixtures
Exact setup time| _dj_autoclear_mailbox function | 0.06 ms |
| _template_string_if_invalid_marker function | 0.04 ms |
| _django_db_marker function | 0.03 ms |
| _live_server_helper function | 0.03 ms |
| _django_set_urlconf function | 0.03 ms |
| _django_isolate_apps function | 0.03 ms |
| _django_clear_site_cache function | 0.02 ms |
| monkeypatch function | 0.02 ms |
Database
28 queries · 21 msNo repeated queries.
Biggest pieces of work
|
call setUp
confs/tests.py:1044
|
435 ms |
|
call test body
confs/tests.py:1079
|
87 ms |
|
call _post_teardown
django/test/testcases.py:1243
|
3 ms |
|
teardown tearDownClass
django/test/testcases.py:1456
|
2 ms |
|
call _pre_setup
django/test/testcases.py:1167
|
1 ms |
Reliability
14 results · 0 CI failures · 0 local failuresThis test hasn't failed recently.
History
Latest 14 results, oldest first in the strip| When | Environment | Outcome | Duration | |
|---|---|---|---|---|
| 2 weeks ago | CI github-actions:test | passed | 528 ms | Profile |
| 2 weeks, 5 days ago | CI github-actions:test | passed | 677 ms | Profile |
| 2 weeks, 6 days ago | CI github-actions:test | passed | 702 ms | Profile |
| 3 weeks ago | CI github-actions:test | passed | 348 ms | Profile |
| 3 weeks ago | CI github-actions:test | passed | 658 ms | Profile |
| 1 month ago | CI github-actions:test | passed | 652 ms | Profile |
| 1 month ago | CI github-actions:test | passed | 494 ms | Profile |
| 1 month ago | CI github-actions:test | passed | 566 ms | Profile |
| 1 month, 1 week ago | CI github-actions:test | passed | 502 ms | Profile |
| 1 month, 1 week ago | CI github-actions:test | passed | 424 ms | Profile |
| 1 month, 1 week ago | CI github-actions:test | passed | 1.15 s | Profile |
| 1 month, 1 week ago | CI github-actions:test | passed | 1.19 s | Profile |
| 1 month, 1 week ago | CI github-actions:test | passed | 1.28 s | Profile |
| 1 month, 1 week ago | CI github-actions:test | passed | 613 ms | Run |