Skip to content

Commit

Permalink
Fix import errors in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
maribedran committed Sep 26, 2024
1 parent 5405643 commit 137946a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
5 changes: 4 additions & 1 deletion qrcode/tests/test_qrcode_pypng.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
import io
from unittest import mock

import png
import pytest


import qrcode
import qrcode.util
from qrcode.image.pure import PyPNGImage
from qrcode.tests.consts import UNICODE_TEXT

png = pytest.importorskip("png", reason="png is not installed")


def test_render_pypng():
qr = qrcode.QRCode()
Expand Down
1 change: 1 addition & 0 deletions qrcode/tests/test_script.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ def test_stdin_py3_unicodedecodeerror():


def test_optimize():
pytest.importorskip("PyPNG", reason="Requires PyPNG")
main("testtext --optimize 0".split())


Expand Down

0 comments on commit 137946a

Please sign in to comment.