@@ -111,7 +111,7 @@ impl ResolvedClientProtocolConfig {
111111 ( "protocol.spooling.enabled" . to_string ( ) , "true" . to_string ( ) ) ,
112112 (
113113 "protocol.spooling.shared-secret-key" . to_string ( ) ,
114- format ! ( "${{ENV:{secret }}}" , secret = ENV_SPOOLING_SECRET ) ,
114+ format ! ( "${{ENV:{ENV_SPOOLING_SECRET }}}" ) ,
115115 ) ,
116116 ] ) ;
117117 }
@@ -128,17 +128,19 @@ mod tests {
128128
129129 #[ tokio:: test]
130130 async fn test_spooling_config ( ) {
131- let config = ClientProtocolConfig :: Spooling ( ClientSpoolingProtocolConfig {
132- location : "s3://my-bucket/spooling" . to_string ( ) ,
133- filesystem : SpoolingFileSystemConfig :: S3 ( S3Config {
134- connection :
135- stackable_operator:: crd:: s3:: v1alpha1:: InlineConnectionOrReference :: Reference (
136- "test-s3-connection" . to_string ( ) ,
137- ) ,
138- iam_role : None ,
139- external_id : None ,
140- } ) ,
141- } ) ;
131+ let config_yaml = indoc:: indoc! { r#"
132+ spooling:
133+ location: s3://my-bucket/spooling
134+ filesystem:
135+ s3:
136+ connection:
137+ reference: test-s3-connection
138+ "# } ;
139+
140+ let deserializer = serde_yaml:: Deserializer :: from_str ( config_yaml) ;
141+ let config = serde_yaml:: with:: singleton_map_recursive:: deserialize ( deserializer)
142+ . expect ( "invalid test input" ) ;
143+
142144
143145 let resolved_spooling_config = ResolvedClientProtocolConfig :: from_config (
144146 & config, None , // No client, so no external resolution
0 commit comments