Skip to content

Commit

Permalink
Step.
Browse files Browse the repository at this point in the history
  • Loading branch information
janiversen committed Jan 6, 2025
1 parent a46e725 commit 70e481c
Show file tree
Hide file tree
Showing 9 changed files with 15 additions and 17 deletions.
6 changes: 3 additions & 3 deletions pymodbus/simulator/__init__.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
"""Simulator."""

__all__ = [
"SimulatorRegisterConfig",
"SimulatorData",
]

from pymodbus.simulator.simregconfig import (
SimulatorRegisterConfig,
from pymodbus.simulator.simdata import (
SimulatorData,
)
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
from enum import Enum


class SimulatorRegisterConfig:
class SimulatorData: # pylint: disable=too-few-public-methods
"""Configure a set of registers."""

class REGISTERTYPE(Enum):
class TYPE(Enum):
"""Register types, used to define group of registers."""

INT16 = 1
Expand All @@ -22,7 +22,7 @@ class REGISTERTYPE(Enum):
BITS = 10
REGISTERS = 11

class REGISTERBLOCK(Enum):
class BLOCK(Enum):
"""Define the block to which a register group belongs."""

SHARED = 0
Expand All @@ -34,11 +34,10 @@ class REGISTERBLOCK(Enum):

def __init__(self,
start_register: int,
datatype: REGISTERTYPE,
datatype: TYPE,
count: int,
*,
action=None,
block: REGISTERBLOCK = REGISTERBLOCK.SHARED
block: BLOCK = BLOCK.SHARED
):
"""Define a group of registers."""
pass
1 change: 0 additions & 1 deletion test/examples/__init__.py

This file was deleted.

1 change: 0 additions & 1 deletion test/framer/__init__.py

This file was deleted.

3 changes: 1 addition & 2 deletions test/framer/test_framer.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,7 @@
FramerType,
)
from pymodbus.pdu import DecodePDU, ModbusPDU

from .generator import set_calls
from test.framer.generator import set_calls


class TestFramer:
Expand Down
1 change: 0 additions & 1 deletion test/pdu/__init__.py

This file was deleted.

3 changes: 1 addition & 2 deletions test/pdu/test_register_write_messages.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@
WriteSingleRegisterRequest,
WriteSingleRegisterResponse,
)

from ..conftest import MockLastValuesContext
from test.conftest import MockLastValuesContext


# ---------------------------------------------------------------------------#
Expand Down
5 changes: 5 additions & 0 deletions test/simulator/test_simdata.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
"""Test pdu."""


class TestSimData:
"""Test simulator data config."""
1 change: 0 additions & 1 deletion test/transport/__init__.py

This file was deleted.

0 comments on commit 70e481c

Please sign in to comment.