mirror of
https://github.com/inventree/InvenTree.git
synced 2025-06-18 21:15:41 +00:00
Add some unit testing
This commit is contained in:
@ -38,4 +38,5 @@ class CompanyConfig(AppConfig):
|
||||
company.image = None
|
||||
company.save()
|
||||
except (OperationalError, ProgrammingError):
|
||||
print("Could not generate Company thumbnails")
|
||||
# Getting here probably meant the database was in test mode
|
||||
pass
|
||||
|
@ -24,7 +24,6 @@ def reverse_association(apps, schema_editor):
|
||||
# Exit if there are no SupplierPart objects
|
||||
# This crucial otherwise the unit test suite fails!
|
||||
if SupplierPart.objects.count() == 0:
|
||||
print("No SupplierPart objects - skipping")
|
||||
return
|
||||
|
||||
print("Reversing migration for manufacturer association")
|
||||
@ -105,7 +104,6 @@ def associate_manufacturers(apps, schema_editor):
|
||||
# Exit if there are no SupplierPart objects
|
||||
# This crucial otherwise the unit test suite fails!
|
||||
if SupplierPart.objects.count() == 0:
|
||||
print("No SupplierPart objects - skipping")
|
||||
return
|
||||
|
||||
# Link a 'manufacturer_name' to a 'Company'
|
||||
|
Reference in New Issue
Block a user