mirror of
https://github.com/Athou/commafeed.git
synced 2026-03-21 21:37:29 +00:00
24 lines
765 B
Java
24 lines
765 B
Java
package com.commafeed.integration;
|
|
|
|
import org.junit.jupiter.params.ParameterizedTest;
|
|
import org.junit.jupiter.params.provider.ValueSource;
|
|
|
|
import io.quarkus.test.junit.QuarkusTest;
|
|
import io.restassured.RestAssured;
|
|
|
|
@QuarkusTest
|
|
class StaticFilesIT {
|
|
|
|
@ParameterizedTest
|
|
@ValueSource(strings = { "/", "/openapi.json", "/openapi.yaml" })
|
|
void servedWithoutCache(String path) {
|
|
RestAssured.given().when().get(path).then().statusCode(200).header("Cache-Control", "no-cache, no-store, must-revalidate");
|
|
}
|
|
|
|
@ParameterizedTest
|
|
@ValueSource(strings = { "/favicon.ico" })
|
|
void servedWithCache(String path) {
|
|
RestAssured.given().when().get(path).then().statusCode(200).header("Cache-Control", "public, immutable, max-age=86400");
|
|
}
|
|
}
|