summaryrefslogtreecommitdiff
path: root/factory/base.py
diff options
context:
space:
mode:
Diffstat (limited to 'factory/base.py')
-rw-r--r--factory/base.py26
1 files changed, 0 insertions, 26 deletions
diff --git a/factory/base.py b/factory/base.py
index 9e07899..efff976 100644
--- a/factory/base.py
+++ b/factory/base.py
@@ -21,7 +21,6 @@
# THE SOFTWARE.
import logging
-import warnings
from . import containers
from . import declarations
@@ -109,23 +108,6 @@ class FactoryMetaClass(type):
attrs_meta = attrs.pop('Meta', None)
- oldstyle_attrs = {}
- converted_attrs = {}
- for old_name, new_name in base_factory._OLDSTYLE_ATTRIBUTES.items():
- if old_name in attrs:
- oldstyle_attrs[old_name] = new_name
- converted_attrs[new_name] = attrs.pop(old_name)
- if oldstyle_attrs:
- warnings.warn(
- "Declaring any of %s at class-level is deprecated"
- " and will be removed in the future. Please set them"
- " as %s attributes of a 'class Meta' attribute." % (
- ', '.join(oldstyle_attrs.keys()),
- ', '.join(oldstyle_attrs.values()),
- ),
- PendingDeprecationWarning, 2)
- attrs_meta = type('Meta', (object,), converted_attrs)
-
base_meta = resolve_attribute('_meta', bases)
options_class = resolve_attribute('_options_class', bases, FactoryOptions)
@@ -322,14 +304,6 @@ class BaseFactory(object):
_meta = FactoryOptions()
- _OLDSTYLE_ATTRIBUTES = {
- 'FACTORY_FOR': 'model',
- 'ABSTRACT_FACTORY': 'abstract',
- 'FACTORY_STRATEGY': 'strategy',
- 'FACTORY_ARG_PARAMETERS': 'inline_args',
- 'FACTORY_HIDDEN_ARGS': 'exclude',
- }
-
# ID to use for the next 'declarations.Sequence' attribute.
_counter = None