Beispiel #1
0
    def test_api_parameters(self):
        args = dict(initialImage="BIGIP-tmos-tier2-13.1.0.0.0.931.iso",
                    managementGw="2.2.2.2",
                    managementIp="1.1.1.1/24",
                    managementNetwork="bridged",
                    state="deployed",
                    vlans=["/Common/vlan1", "/Common/vlan2"])

        p = ApiParameters(params=args)
        assert p.initial_image == 'BIGIP-tmos-tier2-13.1.0.0.0.931.iso'
        assert p.mgmt_route == '2.2.2.2'
        assert p.mgmt_address == '1.1.1.1/24'
        assert '/Common/vlan1' in p.vlans
        assert '/Common/vlan2' in p.vlans
Beispiel #2
0
    def test_api_parameters_with_hotfix(self):
        args = dict(initialImage="BIGIP-14.1.0.3-0.0.6.iso",
                    initialHotfix="Hotfix-BIGIP-14.1.0.3.0.5.6-ENG.iso",
                    managementGw="2.2.2.2",
                    managementIp="1.1.1.1/24",
                    managementNetwork="bridged",
                    state="deployed",
                    vlans=["/Common/vlan1", "/Common/vlan2"])

        p = ApiParameters(params=args)
        assert p.initial_image == 'BIGIP-14.1.0.3-0.0.6.iso'
        assert p.initial_hotfix == 'Hotfix-BIGIP-14.1.0.3.0.5.6-ENG.iso'
        assert p.mgmt_route == '2.2.2.2'
        assert p.mgmt_address == '1.1.1.1/24'
        assert '/Common/vlan1' in p.vlans
        assert '/Common/vlan2' in p.vlans