Move available IP/prefix endpoints to API view mixins

This commit is contained in:
jeremystretch
2021-07-16 14:48:42 -04:00
parent 8d8ac70070
commit 747c065213
4 changed files with 194 additions and 181 deletions

View File

@@ -305,6 +305,7 @@ class PrefixTest(APIViewTestCases.APIViewTestCase):
# Retrieve all available IPs
response = self.client.get(url, **self.header)
self.assertHttpStatus(response, status.HTTP_200_OK)
self.assertEqual(len(response.data), 8) # 8 because prefix.is_pool = True
# Change the prefix to not be a pool and try again