@@ -174,17 +174,18 @@ class ClientCompressedUnary: InteroperabilityTest {
174
174
}
175
175
176
176
// With compression expected and enabled.
177
- options. compression = . gzip
178
-
179
- try await testServiceClient. unaryCall (
180
- request: ClientRequest ( message: compressedRequest) ,
181
- options: options
182
- ) { response in
183
- switch response. accepted {
184
- case . success( let success) :
185
- try assertEqual ( success. message. get ( ) . payload. body, Data ( repeating: 0 , count: 314_159 ) )
186
- case . failure:
187
- throw AssertionFailure ( message: " Response should have been accepted. " )
177
+ for algorithm in [ CompressionAlgorithm . gzip, . deflate] {
178
+ options. compression = algorithm
179
+ try await testServiceClient. unaryCall (
180
+ request: ClientRequest ( message: compressedRequest) ,
181
+ options: options
182
+ ) { response in
183
+ switch response. accepted {
184
+ case . success( let success) :
185
+ try assertEqual ( success. message. get ( ) . payload. body, Data ( repeating: 0 , count: 314_159 ) )
186
+ case . failure:
187
+ throw AssertionFailure ( message: " Response should have been accepted. " )
188
+ }
188
189
}
189
190
}
190
191
@@ -266,7 +267,7 @@ class ServerCompressedUnary: InteroperabilityTest {
266
267
request: ClientRequest ( message: compressedRequest)
267
268
) { response in
268
269
// We can't verify that the compression bit was set, instead we verify that the encoding header
269
- // was sent by the server. This isn't quite the same since as it can still be set but the
270
+ // was sent by the server. This isn't quite the same as it can still be set but the
270
271
// compression may _not_ be set.
271
272
try assertTrue ( response. metadata [ " grpc-encoding " ] . contains { $0 != " identity " } )
272
273
0 commit comments