2014-03-14 17:34:49 +00:00
|
|
|
# -*- coding: utf-8 -*-
|
|
|
|
from __future__ import unicode_literals
|
|
|
|
|
2014-11-04 16:27:35 +00:00
|
|
|
from django.db import migrations
|
2014-03-14 17:34:49 +00:00
|
|
|
|
2015-04-04 16:10:26 +00:00
|
|
|
try:
|
|
|
|
from django.contrib.postgres.operations import (
|
2016-04-25 23:30:48 +00:00
|
|
|
CreateExtension, HStoreExtension, UnaccentExtension,
|
2015-04-04 16:10:26 +00:00
|
|
|
)
|
|
|
|
except ImportError:
|
|
|
|
from django.test import mock
|
2016-04-25 23:30:48 +00:00
|
|
|
CreateExtension = mock.Mock()
|
2015-04-04 16:10:26 +00:00
|
|
|
HStoreExtension = mock.Mock()
|
|
|
|
UnaccentExtension = mock.Mock()
|
|
|
|
|
2014-03-14 17:34:49 +00:00
|
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
|
|
|
|
|
|
operations = [
|
2016-04-25 23:30:48 +00:00
|
|
|
# Ensure CreateExtension quotes extension names by creating one with a
|
|
|
|
# dash in its name.
|
|
|
|
CreateExtension('uuid-ossp'),
|
2014-03-14 17:34:49 +00:00
|
|
|
HStoreExtension(),
|
2014-09-05 20:53:11 +00:00
|
|
|
UnaccentExtension(),
|
2014-03-14 17:34:49 +00:00
|
|
|
]
|