Coverage for app/venv/lib/python3.14/site-packages/weblate/checks/admin.py: 83%
10 statements
« prev ^ index » next coverage.py v7.15.2, created at 2026-10-07 07:15 +0000
« prev ^ index » next coverage.py v7.15.2, created at 2026-10-07 07:15 +0000
1# Copyright © Michal Čihař <michal@weblate.org>
2#
3# SPDX-License-Identifier: GPL-3.0-or-later
5from django.conf import settings
6from django.contrib import admin
8from weblate.wladmin.models import WeblateModelAdmin
10from .models import Check
13class CheckAdmin(WeblateModelAdmin):
14 list_display = ("name", "unit", "dismissed")
15 search_fields = ("unit__source", "name")
16 list_filter = ("name", "dismissed")
19# Show some controls only in debug mode
20if settings.DEBUG: 20 ↛ 21line 20 didn't jump to line 21 because the condition on line 20 was never true
21 admin.site.register(Check, CheckAdmin)