diff options
author | Étienne Loks <etienne.loks@proxience.com> | 2015-06-18 03:16:35 +0200 |
---|---|---|
committer | Étienne Loks <etienne.loks@proxience.com> | 2015-06-18 03:16:35 +0200 |
commit | 01800a727034607ce1a5b824c6aa28e2920a9aa0 (patch) | |
tree | fcdff4faf6d32f9895fcd414df9a9f2fdd1d1057 /archaeological_operations/tests.py | |
parent | bc7a7480fefdcc4a5259fa3444ea9fcd4900ed34 (diff) | |
download | Ishtar-01800a727034607ce1a5b824c6aa28e2920a9aa0.tar.bz2 Ishtar-01800a727034607ce1a5b824c6aa28e2920a9aa0.zip |
Parcels: automatically create external id for parcels
Diffstat (limited to 'archaeological_operations/tests.py')
-rw-r--r-- | archaeological_operations/tests.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/archaeological_operations/tests.py b/archaeological_operations/tests.py index 73f462895..484e2b259 100644 --- a/archaeological_operations/tests.py +++ b/archaeological_operations/tests.py @@ -151,7 +151,7 @@ class ImportOperationTest(TestCase): self.assertTrue(current_nb == (old_nb + 2)) # and well imported last_parcels = models.Parcel.objects.order_by('-pk').all()[0:2] - external_ids = sorted(['XXXX', 'YYYY']) + external_ids = sorted(['XXXX', 'YY55']) parcel_numbers = sorted(['42', '55']) sections = sorted(['ZX', 'YY']) self.assertEqual(external_ids, @@ -164,6 +164,9 @@ class ImportOperationTest(TestCase): towns_ope = last_ope.towns.all() for p in last_parcels: self.assertTrue(p.town in towns_ope) + self.assertEqual(models.Parcel.objects.get(parcel_number='55', + section='YY').external_id, + 'YY55') def testParseParcels(self): |