File tree Expand file tree Collapse file tree 4 files changed +26
-3
lines changed
repository/Zinc-Zodiac-Tests.package
ZnHTTPSTest.class/instance Expand file tree Collapse file tree 4 files changed +26
-3
lines changed Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ testTransfers
1010 https;
1111 host: ' s3-eu-west-1.amazonaws.com' ;
1212 addPath: ' public-stfx-eu' ;
13- addPath: (' test-' , size asString, ' .txt ' );
13+ addPath: (' test-{1}.txt ' format: { size } );
1414 get;
1515 close.
1616 self assert: client isSuccess.
Original file line number Diff line number Diff line change 1+ testing
2+ testTransfersGzip
3+ | client |
4+ self timeLimit: 300 seconds.
5+ self ensureSocketStreamFactory.
6+ self isNativeSSLPluginPresent ifFalse: [ ^ self ].
7+ (client := self httpClient)
8+ https;
9+ host: ' stfx.eu' ;
10+ setAcceptEncodingGzip.
11+ (Integer primesUpTo: 100 ) do: [ :each | | size |
12+ size := 1024 * each + each.
13+ client
14+ url: (' test-{1}.txt' format: { size });
15+ setAcceptEncodingGzip;
16+ get.
17+ self assert: client isSuccess.
18+ self assert: (client response contentType matches: ZnMimeType textPlain).
19+ self assert: client response contentLength equals: size.
20+ self assert: (client response headers at: ' Content-Encoding' ) equals: ' gzip' .
21+ self
22+ assert: client contents
23+ equals: (self class generateTestData: size) ]
Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ testTransfersSingleClient
99 (Integer primesUpTo: 100 ) do: [ :each | | size |
1010 size := 1024 * each + each.
1111 client
12- url: (' /public-stfx-eu/test-' , size asString, ' .txt ' );
12+ url: (' /public-stfx-eu/test-{1}.txt ' format: { size } );
1313 get.
1414 self assert: client isSuccess.
1515 self assert: (client response contentType matches: ZnMimeType textPlain).
Original file line number Diff line number Diff line change 1- SystemOrganization addCategory : #' Zinc-Zodiac-Tests' !
1+ self packageOrganizer ensurePackage : #' Zinc-Zodiac-Tests' withTags: #() !
You can’t perform that action at this time.
0 commit comments