Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


n/n Test CaseTest Case DescriptionTest Case InputsExpected ResultStep by Step ScriptActual resultExpected Result
GraphQL
Actual Result
GraphQL
LE1Register and verify legal entity
  1. legal_entity.json

Response 200

  • LE saved to DB with status mis VERIFIED
  1. Put digital signature to  legal_entity.json
  2. convert it to base64
  3. Register Legal Entity
  4. Verify Legal Entity by MIS



LE2Register and verify legal entity with the same edrpou
  1. Name, Short_name, Public_name - NEW
  2. edrpou - Old

Response 200

  • LE
updates
  • updated in DB with status mis NOT_VERIFIED
  1. Put digital signature to legal_entity
  2. convert it to base64
  3. Register Legal Entity
  • Verify Legal Entity by MIS



  • LE3Register legal entity wrong EDRPOU
    1. edrpou is not 38782323

    Response 422

    • validation_failed
    1. Put digital signature to legal_entity
    2. convert it to base64
    3. Register Legal Entity



    LE4Register legal entity wrong e-mail
    1. e-mail - No

    Response 422

    • validation_failed
    1. Put digital signature to legal_entity
    2. convert it to base64
    3. Register Legal Entity



    LE5Register legal entity wrong address
    1. address area - wrong

    Response 422

    • validation_failed (invalid area value)
    1. Put digital signature to legal_entity
    2. convert it to base64
    3. Register Legal Entity



    LE6Register legal entity w/o scopes
    1. Headers.Authorization - No 

    Response 401

    • access_denied - Authorization header is not set or doesn't contain Bearer token
    1. Put digital signature to legal_entity
    2. convert it to base64
    3. Register Legal Entity



    LE7Register legal entity empty short name
    1. Short_name - empty

    Response 422

    • validation_failed
    1. Put digital signature to legal_entity
    2. convert it to base64
    3. Register Legal Entity



    LE8Register LE not allowed kveds
    1. kveds not in 86.10 or/and 86.21

    Response 422

    • validation_failed 
    • At least one KVED code must be from list [\"86.10\", \"86.21\"]
    1. Put digital signature to legal_entity
    2. convert it to base64
    3. Register Legal Entity



    LE9Register LE w/o legal form
    1. legal_form - No

    Response 422

    • validation_failed
    1. Put digital signature to legal_entity
    2. convert it to base64
    3. Register Legal Entity



    LE10Register closed legal entity
    1. Name, Short_name, Public_name - Old
    2. edrpou - Old
    3. status - CLOSED

    Response 409

    • request_conflict - Legal Entity can't be updated
    1. Put digital signature to legal_entity
    2. convert it to base64
    3. Register Legal Entity



    LE11Deactivate LE
    1. legal entity id - Old

    Response 200

    • LE updated in DB with status CLOSED 
    1. Deactivate Legal Entity

    status='CLOSED'status='CLOSED'
    LE12Deactivate deactivated LE

    legal entity id

    token




    Legal entity is not ACTIVE and cannot be updatedLegal entity is not ACTIVE and cannot be updated
    LE13Deactivate LE without scope

    legal entity id

    token




    [
    {
    "extensions": {
    "code": "FORBIDDEN",
    "exception": {
    "missingAllowances": [
    "legal_entity:deactivate"
    ]
    }
    },
    "message": "Current client is not allowed to access this resource",
    "path": [
    "deactivateLegalEntity"
    ]
    }
    ]
    [
    {
    "extensions": {
    "code": "FORBIDDEN",
    "exception": {
    "missingAllowances": [
    "legal_entity:deactivate"
    ]
    }
    },
    "message": "Current client is not allowed to access this resource",
    "path": [
    "deactivateLegalEntity"
    ]
    }
    ]
    LE14Update LE
    • Name, Short_name, Public_name - New
    • edrpou - Old
    • status - ACTIVE

    Response 200

    legat entity updated in DB with new parameters

    1. Put digital signature to legal_entity
    2. convert it to base64
    3. Register Legal Entity



    LE15Verify LE



    "nhsVerified": true"nhsVerified": true
    LE16Verify LE without scope



    "errors": [
    {
    "extensions": {
    "code": "FORBIDDEN",
    "exception": {
    "missingAllowances": [
    "legal_entity:nhs_verify"
    ]
    }
    },
    "message": "Current client is not allowed to access this resource",
    "path": [
    "nhsVerifyLegalEntity"
    ]
    }
    ]
    "errors": [
    {
    "extensions": {
    "code": "FORBIDDEN",
    "exception": {
    "missingAllowances": [
    "legal_entity:nhs_verify"
    ]
    }
    },
    "message": "Current client is not allowed to access this resource",
    "path": [
    "nhsVerifyLegalEntity"
    ]
    }
    ]
    LE17Verify verified LE



    "errors": [
    {
    "extensions": {
    "code": "CONFLICT"},
    "message": "LegalEntity is VERIFIED and cannot be VERIFIED.",
    "path": [
    "nhsVerifyLegalEntity"]
    }
    ]
    "errors": [
    {
    "extensions": {
    "code": "CONFLICT"},
    "message": "LegalEntity is VERIFIED and cannot be VERIFIED.",
    "path": [
    "nhsVerifyLegalEntity"]
    }
    ]
    LE18Verify LE which doesn't exist



    "errors": [
    {
    "extensions": {
    "code": "NOT_FOUND"
    },
    "message": "LegalEntity not found",
    "path": [
    "nhsVerifyLegalEntity"
    ]
    }
    ]
    "errors": [
    {
    "extensions": {
    "code": "NOT_FOUND"
    },
    "message": "LegalEntity not found",
    "path": [
    "nhsVerifyLegalEntity"
    ]
    }
    ]
    LE19Verify CLOSED LE



    errors
    Legal entity is not ACTIVE and cannot be updated
    "extensions": { "code": "CONFLICT"},
    "message": "Legal entity is not ACTIVE and cannot be updated"