Skip to content

GitHub Projects V2 Testing Setup - Complete

Date: 2026-01-13 Status: ✅ Complete Related PR: #60 Fix priorities not syncing with Github issue submissions

Problem Statement / Goal

Enable isolated local testing of the GitHub Projects V2 integration without affecting production Discord server, Railway deployment, or production GitHub project.

Solution Overview

Created .env.testing file for local testing environment only:

  • Test Discord Guild: 1460766994780520500 (separate test server, not production)
  • Test GitHub Project: Lantern App Testing (keeps test issues separate)
  • Test Milestone: Testing (tags all test submissions)
  • Firebase Database: Dev database (lantern-app-dev) - safe for testing
  • Usage: Local machine only, never committed to repo

Environment Clarification

Three distinct environments:

EnvironmentPurposeGuildDatabaseLocationConfig
Local TestingDev testing before deploymentTest guildDev DBYour machine.env.testing
Dev DeployedStaging/testing after mergeDev guildDev DBRailwayRailway env vars
ProductionLive bot for usersProd guildProd DBRailwayRailway env vars

Files Changed/Created

Local Testing Procedure

Quick Start

bash
cd discord-bot

# Swap to test configuration
mv .env .env.prod
cp .env.testing .env

# Run bot locally
npm start

# Test in Discord test server...

# When done, restore production config
# (Ctrl+C to stop bot first)
# mv .env .env.testing
# mv .env.prod .env

Test Cases

  1. Feature Request (High Priority) → P1 in project
  2. Bug Report (Critical Priority) → P0 in project
  3. Medium Priority Feature → P2 in project
  4. Low Priority Feature → P3 in project

Verification

  • ✅ Issues created in GitHub
  • ✅ Issues appear in "Lantern App Testing" project (not production project)
  • ✅ Priority field populated correctly (P0/P1/P2/P3)
  • ✅ Milestone "Testing" attached
  • ✅ Bot logs show no errors
  • ✅ Test data only in dev Firebase database
  • ✅ Production bot unaffected during testing

Testing Results

Status: Ready to begin testing Setup Complete: Yes Issues Found: None yet - testing in progress

Next Steps

  1. ✅ Test channel IDs obtained and added to .env.testing
  2. ⏳ Run full test suite (all four priority levels)
  3. ⏳ Verify all success cases
  4. ⏳ Document any issues found
  5. Ready to merge PR after all tests pass

Notes

  • Single Discord bot instance handles both test and production (one bot app, multiple guilds)
  • .env.testing never committed - secure and isolated
  • Swap between .env and .env.testing to switch environments
  • Production/Railway completely unaffected during local testing
  • All test data in dev Firebase database - clean isolation

Built with VitePress