Skip to content
Snippets Groups Projects
Select Git revision
  • 2d1861232c90f88cc854738dff62c882e6ddc92a
  • develop default protected
  • fix/rename-l2c-migrate-dropdown
  • master protected
  • redploy-placement-port
  • authorship-fix-from-develop
  • 1048-service-config-backfilling
  • feature/nat-1211-edgeport-lacp-xmit
  • fix/nat-1120-sdp-validation
  • NAT-1154-import-edge-port-update
  • fix/l3-imports
  • feature/10GGBS-NAT-980
  • fix/NAT-1009/fix-redeploy-base-config-if-there-is-a-vprn
  • 4.14
  • 4.13
  • 4.12
  • 4.11
  • 4.10
  • 4.8
  • 4.5
  • 4.4
  • 4.3
  • 4.2
  • 4.1
  • 4.0
  • 3.12
  • 3.11
  • 3.10
  • 3.9
  • 3.8
  • 3.7
  • 3.6
  • 3.5
33 results

setup.py

Blame
  • test_organization.py 781 B
    import json
    import jsonschema
    from compendium_v2.routes.organization import ORGANIZATION_RESPONSE_SCHEMA
    
    
    def test_parentorganization_response(client, test_organization_data):
        rv = client.get(
            '/api/organization/parent',
            headers={'Accept': ['application/json']})
        assert rv.status_code == 200
        result = json.loads(rv.data.decode('utf-8'))
        jsonschema.validate(result, ORGANIZATION_RESPONSE_SCHEMA)
        assert result
    
    
    def test_suborganization_response(client, test_organization_data):
        rv = client.get(
            '/api/organization/sub',
            headers={'Accept': ['application/json']})
        assert rv.status_code == 200
        result = json.loads(rv.data.decode('utf-8'))
        jsonschema.validate(result, ORGANIZATION_RESPONSE_SCHEMA)
        assert result