QAC-Portal/QA-Portal

Change cv-api test config

Open

#174 opened on Dec 16, 2019

 (0 comments) (0 reactions) (0 assignees)Java (5 forks)auto 404
Low PriorityTestinggood first issuejava

Repository metrics

Stars
 (2 stars)
PR merge metrics
 (PR metrics pending)

Description

Currently, tests for cv-api rely on their own config file, cv-api/src/test/resources/application.yml.

This is necessary for line #35: enable_public_endpoints: true

This overrides development's default application.yml file, where this value is set to false, and is necessary for smoke testing the PublicCvManagementController.

However as seen by #173, this causes issue every time the cv-api config is changed.

Rather than duplicate all changes to the main config file in the test package's config file, a better solution might be to implement Spring Boot's @ActiveProfiles annotation, which allows the tests to load their own altered version of application.yml.

Contributor guide