Page Menu
Home
Software Heritage
Search
Configure Global Search
Log In
Files
F7066434
D2683.id9579.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
741 B
Subscribers
None
D2683.id9579.diff
View Options
diff --git a/swh/scheduler/tests/test_scheduler.py b/swh/scheduler/tests/test_scheduler.py
--- a/swh/scheduler/tests/test_scheduler.py
+++ b/swh/scheduler/tests/test_scheduler.py
@@ -16,6 +16,7 @@
import psycopg2
import pytest
+from swh.core.api import RemoteException
from .common import tasks_from_template, TEMPLATES, TASK_TYPES
@@ -38,7 +39,7 @@
tt = TASK_TYPES['git']
swh_scheduler.create_task_type(tt)
assert tt == swh_scheduler.get_task_type(tt['type'])
- with pytest.raises(psycopg2.IntegrityError,
+ with pytest.raises((psycopg2.IntegrityError, RemoteException),
match=r'\(type\)=\(%s\)' % tt['type']):
swh_scheduler.create_task_type(tt)
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Nov 5 2024, 8:41 AM (11 w, 18 h ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3222207
Attached To
D2683: Make create_task_type idempotent
Event Timeline
Log In to Comment