[DB-GOV-02] Preparation of the Test Record Matrix and Access Tokens (Data Seeding)

Database: Populating Data

Published

October 14, 2026

NoteTask Brief
  • Component: gov_registry_db (PostgreSQL).
  • Task Type: Database / Test Data.
  • Associated Business Scenarios: Tests twin.1, twin.2, twin.3
  • Status: Ready for Implementation

Task Description

Populate tables with test data (seeding) to fulfill the validation requirements inside the soapHandler method and debug integration scenarios via Postman.

Step-by-Step Instructions (SQL)

  1. Generating the Master Access Token: Insert a record into the service_access_tokens table to authorize gateway clients:
    • token_value: 'gos_master_secure_token_2026'
    • is_active: true
  2. Populating the Employee Matrix (Scenarios): Insert records into the digital_employees table to emulate the following server responses:
    • Scenario 1 (Success / twin.1): A record with email = 'twin.1@example.com', fully populated personal data, and gov_status = 'ACTIVE'.
    • Scenario 2 (Blocked / twin.2): A record with email = 'twin.2@example.com' and gov_status = 'BLOCKED' (to trigger the GOV_ACCOUNT_BLOCKED handler in the codebase).
    • Scenario 3 (Missing / twin.3): Ensure that a record with email = 'twin.3@example.com' is completely absent from the seeding scripts so that the lookup returns sql.ErrNoRows and throws a USER_NOT_FOUND error.