Skip to content

Commit c164c54

Browse files
Revert "Stop cothread on Win+another Python2 string fix"
This reverts commit da1dca9.
1 parent e93cd1b commit c164c54

1 file changed

Lines changed: 3 additions & 5 deletions

File tree

‎tests/test_records.py‎

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
from enum import Enum
1010

11-
from softioc import builder, softioc, asyncio_dispatcher
11+
from softioc import builder, softioc
1212
from epicsdbbuilder import ResetRecords
1313
from softioc.device_core import RecordLookup
1414
import sim_records
@@ -164,7 +164,7 @@ def record_value_asserts(
164164
else:
165165
# Python2 handles UTF-8 differently so needs extra encoding
166166
if sys.version_info < (3,) and expected_type == str:
167-
expected_value = expected_value.decode(errors="replace")
167+
expected_value = expected_value.encode('utf-8')
168168

169169
assert actual_value == expected_value
170170
assert type(actual_value) == expected_type
@@ -229,10 +229,8 @@ def value_test_function(creation_func, initial_value, queue, set_enum):
229229
if set_enum == SetValueEnum.SET_BEFORE_INIT:
230230
out_rec.set(initial_value)
231231

232-
dispatcher = asyncio_dispatcher.AsyncioDispatcher()
233-
234232
builder.LoadDatabase()
235-
softioc.iocInit(dispatcher)
233+
softioc.iocInit()
236234

237235
if set_enum == SetValueEnum.SET_AFTER_INIT:
238236
out_rec.set(initial_value)

0 commit comments

Comments
 (0)