Skip to content

Feature/GPCAPIM 351 tests for GPProvider stub#171

Draft
DWolfsNHS wants to merge 13 commits intomainfrom
feature/GPCAPIM-351_tests_for_GPProvider_stub
Draft

Feature/GPCAPIM 351 tests for GPProvider stub#171
DWolfsNHS wants to merge 13 commits intomainfrom
feature/GPCAPIM-351_tests_for_GPProvider_stub

Conversation

@DWolfsNHS
Copy link
Copy Markdown
Collaborator

Add contract testing for ProviderStub

Description

Context

Type of changes

  • Refactoring (non-breaking change)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would change existing functionality)
  • Bug fix (non-breaking change which fixes an issue)

Checklist

  • I have followed the code style of the project
  • I have added tests to cover my changes
  • I have updated the documentation accordingly
  • This PR is a result of pair or mob programming
  • Exceptions/Exclusions to coding standards (e.g. #noqa or #NOSONAR) are included within this Pull Request.

Sensitive Information Declaration

To ensure the utmost confidentiality and protect your and others privacy, we kindly ask you to NOT including PII (Personal Identifiable Information) / PID (Personal Identifiable Data) or any other sensitive data in this PR (Pull Request) and the codebase changes. We will remove any PR that do contain any sensitive information. We really appreciate your cooperation in this matter.

  • I confirm that neither PII/PID nor sensitive data are included in this PR and the codebase changes.

- Add assertions to validate response headers and body structure
- Verify that the response contains the expected resource type and entry details
- Implement tests for missing headers in the POST request
- Validate JWT format in the Authorization header
- Ensure correct error responses for invalid requests
…d endpoint

- Implement tests for invalid Content-Type header
- Add tests for invalid Interaction ID header
- Include tests for JWT decoding and validation errors
- Add type check for diagnostics to ensure it is a string
- Confirm error message for authorization header format in validation tests
- Add formatting rules for Python files and Markdown content
- Include guidelines for Terraform file compatibility
- Expand vocabulary list for Vale checks
…acts

- Add exclusions for generated artefacts, lock files, and data fixtures
- Include paths for NHS codes and FHIR field names in cSpell ignore list
- Expand cSpell dictionary with additional terms
- Correct minor spelling errors in comments and documentation
- Rename parameter for clarity from 'pract' to 'practitioner'
- Update error handling to use 'practitioner_errors' for consistency
- Ensure validation checks for resourceType and identifiers are clear and concise
- Add entry for local contract test pact output
- Excluded the pact output file for local contract tests
- Eliminate unnecessary check for trace_id being None as the `get` method provides a fallback
- Remove trace_id from request to provider_stub
- Rename test class for header validation errors
- Add test for missing body in structured record request
- Ensure proper error handling and response for missing body
@sonarqubecloud
Copy link
Copy Markdown

@github-actions
Copy link
Copy Markdown

Deployment Complete

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant