Skip to content

Commit

Permalink
Rename device_simulation file to device_component
Browse files Browse the repository at this point in the history
  • Loading branch information
abbiemery committed Sep 13, 2023
1 parent ab663c4 commit 7145fba
Show file tree
Hide file tree
Showing 19 changed files with 20 additions and 20 deletions.
4 changes: 2 additions & 2 deletions docs/user/reference/api.rst
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,10 @@ This is the internal API reference for tickit
``tickit.core.components.component``
------------------------------------

.. automodule:: tickit.core.components.device_simulation
.. automodule:: tickit.core.components.device_component
:members:

``tickit.core.components.device_simulation``
``tickit.core.components.device_component``
--------------------------------------------

.. automodule:: tickit.core.components.system_simulation
Expand Down
2 changes: 1 addition & 1 deletion docs/user/tutorials/create-a-device.rst
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ if the device requires any adapters to control it externally.
import pydantic.v1.dataclasses
from tickit.core.components.component import Component, ComponentConfig
from tickit.core.components.device_simulation import DeviceComponent
from tickit.core.components.device_component import DeviceComponent
@pydantic.v1.dataclasses.dataclass
Expand Down
2 changes: 1 addition & 1 deletion examples/adapters/http_adapter.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from tickit.adapters.specifications import HttpEndpoint
from tickit.core.adapter import AdapterContainer
from tickit.core.components.component import Component, ComponentConfig
from tickit.core.components.device_simulation import DeviceComponent
from tickit.core.components.device_component import DeviceComponent
from tickit.devices.iobox import IoBoxDevice


Expand Down
2 changes: 1 addition & 1 deletion examples/adapters/system_simulation_adapter.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
from tickit.adapters.system import BaseSystemSimulationAdapter
from tickit.adapters.tcp import CommandAdapter
from tickit.core.components.component import BaseComponent
from tickit.core.components.device_simulation import DeviceComponent
from tickit.core.components.device_component import DeviceComponent
from tickit.core.typedefs import ComponentID
from tickit.utils.byte_format import ByteFormat

Expand Down
2 changes: 1 addition & 1 deletion examples/adapters/zeromq_push_adapter.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
from tickit.adapters.zmq import ZeroMqPushAdapter
from tickit.core.adapter import AdapterContainer
from tickit.core.components.component import Component, ComponentConfig
from tickit.core.components.device_simulation import DeviceComponent
from tickit.core.components.device_component import DeviceComponent
from tickit.devices.iobox import IoBoxDevice


Expand Down
2 changes: 1 addition & 1 deletion examples/devices/amplifier.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
from tickit.adapters.tcp import CommandAdapter
from tickit.core.adapter import AdapterContainer
from tickit.core.components.component import Component, ComponentConfig
from tickit.core.components.device_simulation import DeviceComponent
from tickit.core.components.device_component import DeviceComponent
from tickit.core.device import Device, DeviceUpdate
from tickit.core.typedefs import SimTime
from tickit.utils.byte_format import ByteFormat
Expand Down
2 changes: 1 addition & 1 deletion examples/devices/counter.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import pydantic.v1.dataclasses

from tickit.core.components.component import Component, ComponentConfig
from tickit.core.components.device_simulation import DeviceComponent
from tickit.core.components.device_component import DeviceComponent
from tickit.core.device import Device, DeviceUpdate
from tickit.core.typedefs import SimTime

Expand Down
2 changes: 1 addition & 1 deletion examples/devices/isolated_device.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
from tickit.adapters.tcp import CommandAdapter
from tickit.core.adapter import AdapterContainer
from tickit.core.components.component import Component, ComponentConfig
from tickit.core.components.device_simulation import DeviceComponent
from tickit.core.components.device_component import DeviceComponent
from tickit.core.device import Device, DeviceUpdate
from tickit.core.typedefs import SimTime
from tickit.utils.byte_format import ByteFormat
Expand Down
2 changes: 1 addition & 1 deletion examples/devices/remote_controlled.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
from tickit.adapters.tcp import CommandAdapter
from tickit.core.adapter import AdapterContainer
from tickit.core.components.component import Component, ComponentConfig
from tickit.core.components.device_simulation import DeviceComponent
from tickit.core.components.device_component import DeviceComponent
from tickit.core.device import Device, DeviceUpdate
from tickit.core.typedefs import SimTime
from tickit.utils.byte_format import ByteFormat
Expand Down
2 changes: 1 addition & 1 deletion examples/devices/shutter.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
from tickit.adapters.tcp import CommandAdapter
from tickit.core.adapter import AdapterContainer
from tickit.core.components.component import Component, ComponentConfig
from tickit.core.components.device_simulation import DeviceComponent
from tickit.core.components.device_component import DeviceComponent
from tickit.core.device import Device, DeviceUpdate
from tickit.core.typedefs import SimTime
from tickit.utils.byte_format import ByteFormat
Expand Down
2 changes: 1 addition & 1 deletion examples/devices/trampoline.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import pydantic.v1.dataclasses

from tickit.core.components.component import Component, ComponentConfig
from tickit.core.components.device_simulation import DeviceComponent
from tickit.core.components.device_component import DeviceComponent
from tickit.core.device import Device, DeviceUpdate
from tickit.core.typedefs import SimTime

Expand Down
2 changes: 1 addition & 1 deletion src/tickit/devices/iobox.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
from typing_extensions import NotRequired

from tickit.core.components.component import Component, ComponentConfig
from tickit.core.components.device_simulation import DeviceComponent
from tickit.core.components.device_component import DeviceComponent
from tickit.core.device import Device, DeviceUpdate
from tickit.core.typedefs import SimTime

Expand Down
2 changes: 1 addition & 1 deletion src/tickit/devices/sink.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import pydantic.v1.dataclasses

from tickit.core.components.component import Component, ComponentConfig
from tickit.core.components.device_simulation import DeviceComponent
from tickit.core.components.device_component import DeviceComponent
from tickit.core.device import Device, DeviceUpdate
from tickit.core.typedefs import SimTime

Expand Down
2 changes: 1 addition & 1 deletion src/tickit/devices/source.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import pydantic.v1.dataclasses

from tickit.core.components.component import Component, ComponentConfig
from tickit.core.components.device_simulation import DeviceComponent
from tickit.core.components.device_component import DeviceComponent
from tickit.core.device import Device, DeviceUpdate
from tickit.core.typedefs import SimTime

Expand Down
4 changes: 2 additions & 2 deletions tests/core/components/test_device_simulation.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
from tickit.adapters.io.tcp_io import TcpIo
from tickit.adapters.tcp import CommandAdapter
from tickit.core.adapter import AdapterContainer
from tickit.core.components.device_simulation import DeviceComponent
from tickit.core.components.device_component import DeviceComponent
from tickit.core.state_interfaces.state_interface import StateConsumer, StateProducer
from tickit.core.typedefs import (
Changes,
Expand Down Expand Up @@ -60,7 +60,7 @@ def mock_state_consumer_type() -> Mock:
@pytest.fixture
def patch_asyncio_wait() -> Iterable[Mock]:
with patch(
"tickit.core.components.device_simulation.asyncio.wait", autospec=True
"tickit.core.components.device_component.asyncio.wait", autospec=True
) as mock:
yield mock

Expand Down
2 changes: 1 addition & 1 deletion tests/core/test_simulation.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ async def test_running_only_scheduler(
@pytest_asyncio.fixture
async def patch_component_run_forever() -> AsyncGenerator:
with patch(
"tickit.core.components.device_simulation.DeviceComponent.run_forever",
"tickit.core.components.device_component.DeviceComponent.run_forever",
autospec=True,
) as mock:
mock.return_value = asyncio.create_task(asyncio.sleep(1))
Expand Down
2 changes: 1 addition & 1 deletion tests/system_tests/test_with_master.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
from mock import create_autospec

from tickit.core.components.component import Component, ComponentConfig
from tickit.core.components.device_simulation import DeviceComponent
from tickit.core.components.device_component import DeviceComponent
from tickit.core.management.event_router import InverseWiring
from tickit.core.management.schedulers.master import MasterScheduler
from tickit.core.state_interfaces.state_interface import get_interface
Expand Down
2 changes: 1 addition & 1 deletion tests/system_tests/test_with_master_and_slave.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import pytest_asyncio

from tickit.core.components.component import Component, ComponentConfig
from tickit.core.components.device_simulation import DeviceComponent
from tickit.core.components.device_component import DeviceComponent
from tickit.core.components.system_simulation import SystemComponent
from tickit.core.management.event_router import InverseWiring
from tickit.core.management.schedulers.master import MasterScheduler
Expand Down

0 comments on commit 7145fba

Please sign in to comment.