mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2024-12-30 09:48:56 +00:00
Try a different way.
This commit is contained in:
parent
bee295e411
commit
3b52457d1c
@ -14,7 +14,7 @@ from __future__ import annotations
|
|||||||
import time
|
import time
|
||||||
from urllib.parse import unquote as url_unquote, quote as url_quote
|
from urllib.parse import unquote as url_unquote, quote as url_quote
|
||||||
|
|
||||||
from twisted.internet.defer import ensureDeferred
|
from twisted.internet.threads import deferToThread
|
||||||
|
|
||||||
import allmydata.uri
|
import allmydata.uri
|
||||||
from allmydata.util import jsonbytes as json
|
from allmydata.util import jsonbytes as json
|
||||||
@ -253,8 +253,8 @@ def test_status(alice):
|
|||||||
assert found_download, "Failed to find the file we downloaded in the status-page"
|
assert found_download, "Failed to find the file we downloaded in the status-page"
|
||||||
|
|
||||||
|
|
||||||
@run_in_thread
|
@pytest_twisted.ensureDeferred
|
||||||
def test_directory_deep_check(reactor, request, alice):
|
async def test_directory_deep_check(reactor, request, alice):
|
||||||
"""
|
"""
|
||||||
use deep-check and confirm the result pages work
|
use deep-check and confirm the result pages work
|
||||||
"""
|
"""
|
||||||
@ -264,9 +264,11 @@ def test_directory_deep_check(reactor, request, alice):
|
|||||||
required = 2
|
required = 2
|
||||||
total = 4
|
total = 4
|
||||||
|
|
||||||
result = util.reconfigure(reactor, request, alice, (happy, required, total), convergence=None)
|
await util.reconfigure(reactor, request, alice, (happy, required, total), convergence=None)
|
||||||
pytest_twisted.blockon(ensureDeferred(result))
|
await deferToThread(_test_directory_deep_check_blocking, alice)
|
||||||
|
|
||||||
|
|
||||||
|
def _test_directory_deep_check_blocking(alice):
|
||||||
# create a directory
|
# create a directory
|
||||||
resp = requests.post(
|
resp = requests.post(
|
||||||
util.node_url(alice.node_dir, u"uri"),
|
util.node_url(alice.node_dir, u"uri"),
|
||||||
|
Loading…
Reference in New Issue
Block a user