Skip to content

Missing package mock for cross-platform development #99

@sjpark608

Description

@sjpark608

Please package mock line in unittest files which imports peripheral package.

The following import and mock is required for vscode to discover the unittest in Windows environment

import sys
from unittest import mock
sys.modules["periphery"] = mock.MagicMock()

https://github.com/osensa/edgepi-python-sdk/blob/ab02437422b6341932cdb9b778190f8b86c3e834/src/test_edgepi/unit_tests/test_adc/test_adc_state.py#L1-L18

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions