dbus-fast/tests/test_aio_multi_flags.py
pre-commit-ci[bot] bfc8151005
chore(pre-commit.ci): pre-commit autoupdate (#427)
* chore(pre-commit.ci): pre-commit autoupdate

updates:
- [github.com/astral-sh/ruff-pre-commit: v0.1.0 → v0.11.0](https://github.com/astral-sh/ruff-pre-commit/compare/v0.1.0...v0.11.0)

* chore(pre-commit.ci): auto fixes

* chore: fix violations

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: J. Nick Koston <nick@koston.org>
2025-03-17 11:01:24 -10:00

23 lines
602 B
Python

import pytest
from dbus_fast.aio import MessageBus
from dbus_fast.service import ServiceInterface, method
@pytest.mark.asyncio
async def test_multiple_flags_in_message():
class ExampleInterface(ServiceInterface):
def __init__(self, name):
super().__init__(name)
@method()
def Echo(self, what: "s") -> "s":
return what
bus = await MessageBus().connect()
interface = ExampleInterface("test.interface")
bus.export("/test/path", interface)
await bus.request_name("test.name")
bus.disconnect()
await bus.wait_for_disconnect()