Skip to content

Commit 2a04386

Browse files
authored
Use old formatting to keep it compatible with Python 3.5 (#304)
1 parent 42132ff commit 2a04386

File tree

1 file changed

+11
-7
lines changed

1 file changed

+11
-7
lines changed

tests/softhsm_setup.py

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -123,20 +123,24 @@ def setup() -> None:
123123
if softhsm_version == 2:
124124
softhsm_db = _temp_dir()
125125
f.write(
126-
f"""
126+
"""
127127
# Generated by test
128-
directories.tokendir = {softhsm_db}
128+
directories.tokendir = {}
129129
objectstore.backend = file
130130
log.level = DEBUG
131-
"""
131+
""".format(
132+
softhsm_db
133+
)
132134
)
133135
else:
134136
softhsm_db = _temp_file()
135137
f.write(
136-
f"""
138+
"""
137139
# Generated by test
138-
0:{softhsm_db}
139-
"""
140+
0:{}
141+
""".format(
142+
softhsm_db
143+
)
140144
)
141145

142146
logging.debug('Initializing the token')
@@ -223,7 +227,7 @@ def setup() -> None:
223227
'[pkcs11_section]',
224228
'engine_id = pkcs11',
225229
# dynamic_path,
226-
f"MODULE_PATH = {component_path['P11_MODULE']}",
230+
"MODULE_PATH = {}".format(component_path['P11_MODULE']),
227231
'init = 0',
228232
]
229233
)

0 commit comments

Comments
 (0)