mirror of
https://github.com/netbox-community/netbox.git
synced 2026-04-10 03:13:48 +02:00
16783 Add status field to InventoryItem (#17627)
* 16783 Add status field to InventoryItem * 16783 fix tests * 16783 fix tests * 16783 review changes
This commit is contained in:
@@ -2903,6 +2903,7 @@ class InventoryItemTestCase(ViewTestCases.DeviceComponentViewTestCase):
|
||||
'part_id': '123456',
|
||||
'serial': '123ABC',
|
||||
'asset_tag': 'ABC123',
|
||||
'status': InventoryItemStatusChoices.STATUS_ACTIVE,
|
||||
'description': 'An inventory item',
|
||||
'tags': [t.pk for t in tags],
|
||||
}
|
||||
@@ -2916,6 +2917,7 @@ class InventoryItemTestCase(ViewTestCases.DeviceComponentViewTestCase):
|
||||
'discovered': False,
|
||||
'part_id': '123456',
|
||||
'serial': '123ABC',
|
||||
'status': InventoryItemStatusChoices.STATUS_ACTIVE,
|
||||
'description': 'An inventory item',
|
||||
'tags': [t.pk for t in tags],
|
||||
}
|
||||
@@ -2927,10 +2929,10 @@ class InventoryItemTestCase(ViewTestCases.DeviceComponentViewTestCase):
|
||||
}
|
||||
|
||||
cls.csv_data = (
|
||||
"device,name,parent",
|
||||
"Device 1,Inventory Item 4,Inventory Item 1",
|
||||
"Device 1,Inventory Item 5,Inventory Item 2",
|
||||
"Device 1,Inventory Item 6,Inventory Item 3",
|
||||
"device,name,parent,status",
|
||||
"Device 1,Inventory Item 4,Inventory Item 1,active",
|
||||
"Device 1,Inventory Item 5,Inventory Item 2,planned",
|
||||
"Device 1,Inventory Item 6,Inventory Item 3,failed",
|
||||
)
|
||||
|
||||
cls.csv_update_data = (
|
||||
|
||||
Reference in New Issue
Block a user