|
@@ -67,3 +67,18 @@ class VPNTestCase(TestCase):
|
|
|
subnet = abo.ip_subnet.get(ip_pool=self.v6_pool)
|
|
|
self.assertIn(vpn.ipv6_endpoint, subnet.inet)
|
|
|
|
|
|
+ def test_change_v4subnet_is_vpn_endpoint_correct(self):
|
|
|
+ abo = OfferSubscription.objects.get()
|
|
|
+ subnet = abo.ip_subnet.get(ip_pool=self.v4_pool)
|
|
|
+ subnet.inet = "192.168.42.42/31"
|
|
|
+ subnet.full_clean()
|
|
|
+ subnet.save()
|
|
|
+ self.test_has_correct_ipv4_endpoint()
|
|
|
+
|
|
|
+ def test_change_v6subnet_is_vpn_endpoint_correct(self):
|
|
|
+ abo = OfferSubscription.objects.get()
|
|
|
+ subnet = abo.ip_subnet.get(ip_pool=self.v6_pool)
|
|
|
+ subnet.inet = "2001:db8:4242:4200::/56"
|
|
|
+ subnet.full_clean()
|
|
|
+ subnet.save()
|
|
|
+ self.test_has_correct_ipv6_endpoint()
|