Skip to content

Cache Recovery and Completion Tests#86

Open
DanielDango wants to merge 5 commits into
ardoco:feature/add-cache-configurationsfrom
DanielDango:feature/add-cache-configurations-recovery-test
Open

Cache Recovery and Completion Tests#86
DanielDango wants to merge 5 commits into
ardoco:feature/add-cache-configurationsfrom
DanielDango:feature/add-cache-configurations-recovery-test

Conversation

@DanielDango

Copy link
Copy Markdown
Collaborator

Depends on #75
@dfuchss this can be merged into #75 if the tests should remain part of the project.

This PR introduces integration tests for the configurable multi-layered caches.
Using a testcontainer a Redis instance is spun up to verify various expected behaviours of the new hierarchical cache when combining the existing local and Redis cache implementations.

@DanielDango DanielDango requested a review from dfuchss as a code owner June 14, 2026 10:03

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Adds integration coverage for the new configurable hierarchical cache (local + Redis) by spinning up Redis via Testcontainers and validating cache recovery/completion scenarios, plus a small fix to .env loading behavior.

Changes:

  • Add CacheRecoveryIntegrationTest to exercise Local → Redis backfill and Redis → Local recovery/completion flows.
  • Adjust Environment.overwrite(Path) to load dotenv via directory + filename.
  • Add Testcontainers dependencies and introduce a second WARC config that writes cache output to a different directory.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 14 comments.

Show a summary per file
File Description
src/test/resources/warc/config-without-cache.json Adds an alternative evaluation config targeting a separate cache directory for recovery tests.
src/test/resources/warc/cache/SimpleClassifier_gpt-4o-mini-2024-07-18_133742243.json Updates a cached fixture used by the WARC evaluation tests.
src/test/java/edu/kit/kastel/sdq/lissa/ratlr/cache/CacheRecoveryIntegrationTest.java New Redis-backed integration tests validating hierarchical cache recovery/completion/preservation.
src/main/java/edu/kit/kastel/sdq/lissa/ratlr/utils/Environment.java Changes dotenv loading to use directory + filename (but needs a null-parent guard).
pom.xml Adds Testcontainers JUnit integration deps (currently with mismatched versions).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread pom.xml
Comment thread src/main/java/edu/kit/kastel/sdq/lissa/ratlr/utils/Environment.java
@sonarqubecloud

Copy link
Copy Markdown

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.

3 participants