[squeak-dev] The Trunk: MorphicTests-rkrk.11.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[squeak-dev] The Trunk: MorphicTests-rkrk.11.mcz

commits-2
Andreas Raab uploaded a new version of MorphicTests to project The Trunk:
http://source.squeak.org/trunk/MorphicTests-rkrk.11.mcz

==================== Summary ====================

Name: MorphicTests-rkrk.11
Author: rkrk
Time: 24 September 2009, 3:39:36 am
UUID: 7168c8d1-f45b-4968-bbd1-677b6783b81b
Ancestors: MorphicTests-ar.10

Tests for FormCanvas>>frameAndFillRoundRect:radius:fillStyle:borderWidth:borderColor:. It raises errors in degenerate cases when fillStyle is more than a Color (e.g. a GradientFillStyle).

=============== Diff against MorphicTests-ar.10 ===============

Item was added:
+ ----- Method: FormCanvasTest>>testFrameAndFillDegenerateRoundRect02 (in category 'tests') -----
+ testFrameAndFillDegenerateRoundRect02
+
+ | fill canvas smallRect |
+ fill := GradientFillStyle sample.
+ canvas := FormCanvas extent: 100@100.
+ canvas fillColor: Color black.
+ smallRect := 0@0 corner: 20@20.
+ self shouldnt: [
+ canvas
+ frameAndFillRoundRect: smallRect
+ radius: 0
+ fillStyle: fill
+ borderWidth: 0
+ borderColor: Color lightGray]
+ raise: Error.!

Item was changed:
  SystemOrganization addCategory: #'MorphicTests-Basic'!
  SystemOrganization addCategory: #'MorphicTests-Kernel'!
  SystemOrganization addCategory: #'MorphicTests-Text Support'!
  SystemOrganization addCategory: #'MorphicTests-Widgets'!
+ SystemOrganization addCategory: #'MorphicTests-Support'!
  SystemOrganization addCategory: #'MorphicTests-Worlds'!

Item was added:
+ TestCase subclass: #FormCanvasTest
+ instanceVariableNames: 'morph'
+ classVariableNames: ''
+ poolDictionaries: ''
+ category: 'MorphicTests-Support'!

Item was added:
+ ----- Method: FormCanvasTest>>testFrameAndFillDegenerateRoundRect01 (in category 'tests') -----
+ testFrameAndFillDegenerateRoundRect01
+
+ | fill canvas smallRect |
+ fill := GradientFillStyle sample.
+ canvas := FormCanvas extent: 100@100.
+ canvas fillColor: Color black.
+ smallRect := 0@0 corner: 20@20.
+ self shouldnt: [
+ canvas
+ frameAndFillRoundRect: smallRect
+ radius: smallRect width / 2 + 1
+ fillStyle: fill
+ borderWidth: 0
+ borderColor: Color lightGray]
+ raise: Error.!