1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Closes #15238: Include description field in brief mode

This commit is contained in:
Jeremy Stretch
2024-02-23 15:26:06 -05:00
parent 3f3bcc5eb5
commit d042e6f69d
22 changed files with 200 additions and 204 deletions

View File

@ -19,7 +19,7 @@ class AppTest(APITestCase):
class TunnelGroupTest(APIViewTestCases.APIViewTestCase):
model = TunnelGroup
brief_fields = ['display', 'id', 'name', 'slug', 'tunnel_count', 'url']
brief_fields = ['description', 'display', 'id', 'name', 'slug', 'tunnel_count', 'url']
create_data = (
{
'name': 'Tunnel Group 4',
@ -51,7 +51,7 @@ class TunnelGroupTest(APIViewTestCases.APIViewTestCase):
class TunnelTest(APIViewTestCases.APIViewTestCase):
model = Tunnel
brief_fields = ['display', 'id', 'name', 'url']
brief_fields = ['description', 'display', 'id', 'name', 'url']
bulk_update_data = {
'status': TunnelStatusChoices.STATUS_PLANNED,
'encapsulation': TunnelEncapsulationChoices.ENCAP_GRE,
@ -179,7 +179,7 @@ class TunnelTerminationTest(APIViewTestCases.APIViewTestCase):
class IKEProposalTest(APIViewTestCases.APIViewTestCase):
model = IKEProposal
brief_fields = ['display', 'id', 'name', 'url']
brief_fields = ['description', 'display', 'id', 'name', 'url']
bulk_update_data = {
'authentication_method': AuthenticationMethodChoices.CERTIFICATES,
'encryption_algorithm': EncryptionAlgorithmChoices.ENCRYPTION_AES192_CBC,
@ -243,7 +243,7 @@ class IKEProposalTest(APIViewTestCases.APIViewTestCase):
class IKEPolicyTest(APIViewTestCases.APIViewTestCase):
model = IKEPolicy
brief_fields = ['display', 'id', 'name', 'url']
brief_fields = ['description', 'display', 'id', 'name', 'url']
bulk_update_data = {
'version': IKEVersionChoices.VERSION_1,
'mode': IKEModeChoices.AGGRESSIVE,
@ -317,7 +317,7 @@ class IKEPolicyTest(APIViewTestCases.APIViewTestCase):
class IPSecProposalTest(APIViewTestCases.APIViewTestCase):
model = IPSecProposal
brief_fields = ['display', 'id', 'name', 'url']
brief_fields = ['description', 'display', 'id', 'name', 'url']
bulk_update_data = {
'encryption_algorithm': EncryptionAlgorithmChoices.ENCRYPTION_AES192_CBC,
'authentication_algorithm': AuthenticationAlgorithmChoices.AUTH_HMAC_MD5,
@ -367,7 +367,7 @@ class IPSecProposalTest(APIViewTestCases.APIViewTestCase):
class IPSecPolicyTest(APIViewTestCases.APIViewTestCase):
model = IPSecPolicy
brief_fields = ['display', 'id', 'name', 'url']
brief_fields = ['description', 'display', 'id', 'name', 'url']
bulk_update_data = {
'pfs_group': DHGroupChoices.GROUP_5,
'description': 'New description',
@ -429,7 +429,7 @@ class IPSecPolicyTest(APIViewTestCases.APIViewTestCase):
class IPSecProfileTest(APIViewTestCases.APIViewTestCase):
model = IPSecProfile
brief_fields = ['display', 'id', 'name', 'url']
brief_fields = ['description', 'display', 'id', 'name', 'url']
@classmethod
def setUpTestData(cls):
@ -519,7 +519,7 @@ class IPSecProfileTest(APIViewTestCases.APIViewTestCase):
class L2VPNTest(APIViewTestCases.APIViewTestCase):
model = L2VPN
brief_fields = ['display', 'id', 'identifier', 'name', 'slug', 'type', 'url']
brief_fields = ['description', 'display', 'id', 'identifier', 'name', 'slug', 'type', 'url']
create_data = [
{
'name': 'L2VPN 4',