Skip test_sql_migrations on Python 3 for now.
authorBerker Peksag <berker.peksag@gmail.com>
Mon, 28 Jul 2014 10:22:42 +0000 (13:22 +0300)
committerBerker Peksag <berker.peksag@gmail.com>
Mon, 28 Jul 2014 10:22:42 +0000 (13:22 +0300)
mediagoblin/tests/test_sql_migrations.py

index e86dcd80c275c286a86ad10973dc78ff62081388..7e0569adcb349327f8943a9973f2d9fa1230d208 100644 (file)
 # You should have received a copy of the GNU Affero General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-import copy
-
 import six
+import pytest
+
+pytestmark = pytest.mark.skipif(six.PY3, reason='needs sqlalchemy.migrate')
+
+import copy
 
 from sqlalchemy import (
     Table, Column, MetaData, Index,
@@ -25,7 +28,8 @@ from sqlalchemy import (
 from sqlalchemy.orm import sessionmaker, relationship
 from sqlalchemy.ext.declarative import declarative_base
 from sqlalchemy.sql import select, insert
-from migrate import changeset
+if six.PY2:
+    from migrate import changeset
 
 from mediagoblin.db.base import GMGTableBase
 from mediagoblin.db.migration_tools import MigrationManager, RegisterMigration