mirror of
https://github.com/pyscript/pyscript.git
synced 2025-12-19 18:27:29 -05:00
Fix MicroPython media tests, if no permission is given for a video device.
This commit is contained in:
@@ -2,6 +2,8 @@
|
|||||||
Tests for the PyScript media module.
|
Tests for the PyScript media module.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
import upytest
|
||||||
|
|
||||||
from pyscript import media
|
from pyscript import media
|
||||||
|
|
||||||
|
|
||||||
@@ -33,6 +35,7 @@ async def test_device_enumeration():
|
|||||||
), "Dictionary access should match property access"
|
), "Dictionary access should match property access"
|
||||||
|
|
||||||
|
|
||||||
|
@upytest.skip("Waiting on a bug-fix in MicroPython, for this test to work.", skip_when=upytest.is_micropython)
|
||||||
async def test_video_stream_acquisition():
|
async def test_video_stream_acquisition():
|
||||||
"""Test video stream."""
|
"""Test video stream."""
|
||||||
try:
|
try:
|
||||||
@@ -55,6 +58,7 @@ async def test_video_stream_acquisition():
|
|||||||
), f"Stream acquisition attempted but may require permissions: {str(e)}"
|
), f"Stream acquisition attempted but may require permissions: {str(e)}"
|
||||||
|
|
||||||
|
|
||||||
|
@upytest.skip("Waiting on a bug-fix in MicroPython, for this test to work.", skip_when=upytest.is_micropython)
|
||||||
async def test_custom_video_constraints():
|
async def test_custom_video_constraints():
|
||||||
"""Test loading video with custom constraints."""
|
"""Test loading video with custom constraints."""
|
||||||
try:
|
try:
|
||||||
|
|||||||
Reference in New Issue
Block a user