mirror of
https://github.com/fawney19/Aether.git
synced 2026-10-08 18:37:46 +08:00
Revert "Merge remote-tracking branch 'origin/pr/592'"
This reverts commit3504875922, reversing changes made to5c3a1aecbe.
This commit is contained in:
@@ -7,7 +7,6 @@ use crate::tests::{
|
||||
build_state_with_execution_runtime_override, json, start_server, AppState, Arc, Body,
|
||||
FrontdoorCorsConfig, Mutex, Request, Router, StatusCode, FRONTDOOR_MANIFEST_PATH, READYZ_PATH,
|
||||
};
|
||||
use aether_contracts::USAGE_SERVER_NOW_UNIX_MS_HEADER;
|
||||
use aether_crypto::DEVELOPMENT_ENCRYPTION_KEY;
|
||||
use aether_data::repository::auth::InMemoryAuthApiKeySnapshotRepository;
|
||||
use aether_data::repository::candidate_selection::InMemoryMinimalCandidateSelectionReadRepository;
|
||||
@@ -441,19 +440,12 @@ async fn gateway_adds_cors_headers_to_proxied_responses() {
|
||||
.expect("allow origin header"),
|
||||
"http://localhost:3000"
|
||||
);
|
||||
let expose_headers = response_headers
|
||||
.get("access-control-expose-headers")
|
||||
.expect("expose headers header")
|
||||
.to_str()
|
||||
.expect("expose headers should be valid ASCII");
|
||||
assert!(expose_headers
|
||||
.split(',')
|
||||
.map(str::trim)
|
||||
.any(|header| header == "*"));
|
||||
assert!(expose_headers
|
||||
.split(',')
|
||||
.map(str::trim)
|
||||
.any(|header| header.eq_ignore_ascii_case(USAGE_SERVER_NOW_UNIX_MS_HEADER)));
|
||||
assert_eq!(
|
||||
response_headers
|
||||
.get("access-control-expose-headers")
|
||||
.expect("expose headers header"),
|
||||
"*"
|
||||
);
|
||||
assert_eq!(
|
||||
*execution_runtime_hits.lock().expect("mutex should lock"),
|
||||
1
|
||||
|
||||
Reference in New Issue
Block a user