operation: tests: Fix warning when test helpers start with 'Test'

Don't start the helper class name with 'Test' as it will be treated as a class
with test cases to run.

Fixes #2288.

Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
This commit is contained in:
Sunil Mohan Adapa 2023-01-02 16:21:47 -08:00 committed by James Valleroy
parent 99aa6e44f1
commit bc09cd42bb
No known key found for this signature in database
GPG Key ID: 77C0C75E7B650808

View File

@ -14,7 +14,7 @@ from ..notification import Notification
from ..operation import Operation, OperationsManager
class TestApp(app.App):
class AppTest(app.App):
app_id = 'testapp'
def __init__(self):
@ -207,7 +207,7 @@ def test_message(app_get):
@pytest.mark.django_db
def test_update_notification(app_get):
"""Test that operation notification is created."""
app_get.return_value = TestApp()
app_get.return_value = AppTest()
operation = Operation('testapp', 'op1', Mock(), show_notification=True)
note = Notification.get('testapp-operation')
assert note.id == 'testapp-operation'