1. Tarek Ziadé
  2. flake8

Commits

Tarek Ziadé  committed 2454c3b

io under py3

  • Participants
  • Parent commits 25ea751
  • Branches python3

Comments (0)

Files changed (1)

File flake8/tests/test_mccabe.py

View file
  • Ignore whitespace
 import unittest
 import sys
-from StringIO import StringIO
+try:
+    from StringIO import StringIO
+except ImportError:
+    from io import StringIO
 
 from flake8.mccabe import get_code_complexity