|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+from copy import deepcopy
|
|
|
2
|
+
|
|
1
|
3
|
from django.core.exceptions import ValidationError
|
|
2
|
4
|
from django.test import TestCase
|
|
3
|
5
|
|
|
|
@@ -167,6 +169,11 @@ class ProductAttributeTest(TestCase):
|
|
167
|
169
|
"so it saved, even when the parent has the same value",
|
|
168
|
170
|
)
|
|
169
|
171
|
|
|
|
172
|
+ def test_deepcopy(self):
|
|
|
173
|
+ "Deepcopy should not cause a recursion error"
|
|
|
174
|
+ deepcopy(self.product)
|
|
|
175
|
+ deepcopy(self.child_product)
|
|
|
176
|
+
|
|
170
|
177
|
|
|
171
|
178
|
class ProductAttributeQuerysetTest(TestCase):
|
|
172
|
179
|
fixtures = ["productattributes"]
|