Skip to content

test: add test for get production configuration#174

Merged
reddevilmidzy merged 1 commit intomainfrom
test-prod-config
Jul 15, 2025
Merged

test: add test for get production configuration#174
reddevilmidzy merged 1 commit intomainfrom
test-prod-config

Conversation

@reddevilmidzy
Copy link
Owner

♟️ What’s this PR about?

production 환경에서 Secret 값을 가져와 설정 추가하는 로직에 대한 테스트를 추가하였습니다.

Copilot AI review requested due to automatic review settings July 15, 2025 07:32
@github-actions github-actions bot added this to the 5차 MVP 구현 milestone Jul 15, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Adds a unit test for the get_production_configuration function and pulls in the shuttle-common crate to access secret types in tests.

  • Imports Secret and BTreeMap and defines test_get_production_configuration.
  • Adds shuttle-common = "0.56.0" to Cargo.toml.

Reviewed Changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated 1 comment.

File Description
rook/src/configuration.rs Imported secret types and added a new positive test
rook/Cargo.toml Added shuttle-common dependency
Comments suppressed due to low confidence (2)

rook/src/configuration.rs:208

  • The test verifies sender_email and timeout_seconds but misses asserting that authorization_token is correctly applied from secrets. Consider adding assert_eq!(settings.email_client.authorization_token, "veryverysecret");.
        assert_eq!(settings.email_client.timeout_seconds, 10);

rook/src/configuration.rs:148

  • The test references SecretStore but it isn’t imported. Add use shuttle_common::secrets::SecretStore; to ensure the code compiles.
    use shuttle_common::secrets::Secret;

@codecov
Copy link

codecov bot commented Jul 15, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

📢 Thoughts on this report? Let us know!

@reddevilmidzy reddevilmidzy merged commit fe125cd into main Jul 15, 2025
6 checks passed
@reddevilmidzy reddevilmidzy deleted the test-prod-config branch July 15, 2025 08:10
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.

2 participants