summaryrefslogtreecommitdiffstatshomepage
path: root/tests/extmod/asyncio_threadsafeflag.py
diff options
context:
space:
mode:
authorJim Mussared <jim.mussared@gmail.com>2023-09-14 15:26:23 +1000
committerDamien George <damien@micropython.org>2023-09-29 17:58:40 +1000
commitfae83a6b4d0d7b3e4917fdeb9b7966a06161af54 (patch)
tree62318ea8f1dda96496a9ef504c7aaee2be0165c1 /tests/extmod/asyncio_threadsafeflag.py
parentcfe6a11e39725f42ac3fffac138d2de1587fe756 (diff)
downloadmicropython-fae83a6b4d0d7b3e4917fdeb9b7966a06161af54.tar.gz
micropython-fae83a6b4d0d7b3e4917fdeb9b7966a06161af54.zip
tests/extmod/asyncio_threadsafeflag.py: Update for unix select.
1. Remove the skip for detecting support for polling user-defined objects as this is always possible now on all ports. 2. Don't print when the scheduled task runs as the ordering of this relative to the other prints is dependent on other factors (e.g. if using the native emitter). This work was funded through GitHub Sponsors. Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
Diffstat (limited to 'tests/extmod/asyncio_threadsafeflag.py')
-rw-r--r--tests/extmod/asyncio_threadsafeflag.py13
1 files changed, 0 insertions, 13 deletions
diff --git a/tests/extmod/asyncio_threadsafeflag.py b/tests/extmod/asyncio_threadsafeflag.py
index 46da1b7b48..e8798afcf5 100644
--- a/tests/extmod/asyncio_threadsafeflag.py
+++ b/tests/extmod/asyncio_threadsafeflag.py
@@ -16,17 +16,6 @@ except AttributeError:
raise SystemExit
-try:
- # Unix port can't select/poll on user-defined types.
- import select
-
- poller = select.poll()
- poller.register(asyncio.ThreadSafeFlag())
-except TypeError:
- print("SKIP")
- raise SystemExit
-
-
async def task(id, flag):
print("task", id)
await flag.wait()
@@ -34,9 +23,7 @@ async def task(id, flag):
def set_from_schedule(flag):
- print("schedule")
flag.set()
- print("schedule done")
async def main():