Skip to content

Commit

Permalink
Fix failing work queue test (#15709)
Browse files Browse the repository at this point in the history
  • Loading branch information
desertaxle authored Oct 16, 2024
1 parent 755d85a commit 2489411
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions tests/server/models/deprecated/test_work_queues.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import pytest

from prefect.server import models, schemas
from prefect.server.database import orm_models
from prefect.server.exceptions import ObjectNotFoundError
from prefect.server.models.deployments import check_work_queues_for_deployment
from prefect.server.utilities.database import get_dialect
Expand Down Expand Up @@ -50,12 +51,14 @@ async def test_update_work_queue(self, session, work_queue):
)
assert result

queue = await session.get(
orm_models.WorkQueue, work_queue.id, populate_existing=True
)
updated_queue = schemas.core.WorkQueue.model_validate(
await models.work_queues.read_work_queue(
session=session, work_queue_id=work_queue.id
),
queue,
from_attributes=True,
)

assert updated_queue.id == work_queue.id

with pytest.warns(DeprecationWarning):
Expand Down

0 comments on commit 2489411

Please sign in to comment.