[squeak-dev] The Trunk: GraphicsTests-dtl.43.mcz

Levente Uzonyi leves at caesar.elte.hu
Sun Jun 18 20:32:42 UTC 2017


On Sun, 18 Jun 2017, commits at source.squeak.org wrote:

> David T. Lewis uploaded a new version of GraphicsTests to project The Trunk:
> http://source.squeak.org/trunk/GraphicsTests-dtl.43.mcz
>
> ==================== Summary ====================
>
> Name: GraphicsTests-dtl.43
> Author: dtl
> Time: 18 June 2017, 3:23:47.146706 pm
> UUID: c6c174e4-6ce9-445c-aa4b-af5a52869461
> Ancestors: GraphicsTests-pre.42
>
> Add PNGReadWriterTest>>testNewFromSampleBytes based on a problem report by Hilaire Fernandes, and affecting Dr Geo. The test fails on 64 bit Spur if a synthesized LargeInteger parameter to Bitmap #at:put: is not normalized prior to calling the primitive.
>
> Problem reported at http://lists.pharo.org/pipermail/pharo-users_lists.pharo.org/2017-June/032660.html
>
> =============== Diff against GraphicsTests-pre.42 ===============
>
> Item was added:
> + ----- Method: PNGReadWriterTest>>testNewFromSampleBytes (in category 'tests - decoding') -----
> + testNewFromSampleBytes
> + 	"Based on a problem report by Hilaire Fernandes, this fails on 64 bit Spur if a
> + 	synthesized LargeInteger parameter to Bitmap #at:put: is not normalized prior
> + 	to calling the primitive. See problem report at
> + 	http://lists.pharo.org/pipermail/pharo-users_lists.pharo.org/2017-June/032660.html"
> + 
> + 	| sampleBytes png form |
> + 	sampleBytes := #(137 80 78 71 13 10 26 10 0 0 0 13 73 72

Why not a ByteArray literal instead of an Array converted to a ByteArray?

Levente

> + 		68 82 0 0 0 48 0 0 0 48 16 6 0 0 0 7 146 37 196 0 0 0 6 98 75 71 68 255
> + 		255 255 255 255 255 9 88 247 220 0 0 0 9 112 72 89 115 0 0 0 72 0 0 0 72
> + 		0 70 201 107 62 0 0 1 153 73 68 65 84 120 218 237 155 73 110 195 48 12
> + 		69 227 162 183 211 9 180 11 130 220 77 39 208 249 210 77 181 8 81 69 19
> + 		39 169 255 109 12 35 137 197 255 105 81 244 144 219 13 0 0 0 0 0 116 16
> + 		66 8 33 188 94 214 113 120 99 214 151 111 238 1 115 206 57 231 235 178
> + 		54 68 10 238 19 112 58 1 189 1 238 158 16 233 25 255 37 117 224 221 141
> + 		215 210 193 158 128 83 140 215 210 181 156 0 26 216 169 139 180 155 210
> + 		218 50 184 124 126 74 34 122 245 204 234 101 207 224 41 221 145 150 14
> + 		49 67 118 77 132 118 220 98 93 208 168 64 107 172 226 18 63 19 91 194
> + 		172 103 132 117 124 106 194 117 132 210 227 215 143 103 109 124 65 173 4
> + 		181 4 173 149 128 254 223 121 49 190 160 190 6 212 4 126 22 94 12 163 91
> + 		173 241 229 112 219 141 188 51 106 184 223 46 139 162 62 3 164 137 49
> + 		198 24 253 117 89 219 241 183 145 181 82 180 94 154 192 47 212 248 247
> + 		253 209 45 152 102 205 120 36 130 137 182 193 159 19 5 22 233 53 158 126
> + 		31 48 209 54 190 181 15 8 189 247 215 71 141 174 25 127 218 243 137 105
> + 		168 17 53 99 164 140 247 154 8 183 119 67 139 177 41 165 148 210 117 209
> + 		125 233 241 181 16 187 18 158 21 254 124 62 30 247 251 186 241 173 113
> + 		122 227 148 70 237 145 100 175 33 210 120 139 207 205 237 232 255 22 71
> + 		129 45 16 60 3 158 163 123 6 140 214 74 239 198 207 198 201 189 102 12
> + 		151 32 26 128 155 23 150 22 105 189 96 38 181 88 31 211 206 113 163 165
> + 		151 109 17 182 110 231 118 213 193 222 5 237 154 8 171 184 217 254 31
> + 		176 123 9 114 255 146 177 187 128 224 3 0 0 0 0 192 198 252 0 102 116 72
> + 		96 211 171 62 8 0 0 0 0 73 69 78 68 174 66 96 130) asByteArray.
> + 
> + 	png := PNGReadWriter on: sampleBytes readStream.
> + 	form := png nextImage.
> + 	self assert: Form equals: form class.
> + !


More information about the Squeak-dev mailing list