The Inbox: Tests-jr.364.mcz

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

The Inbox: Tests-jr.364.mcz

commits-2
A new version of Tests was added to project The Inbox:
http://source.squeak.org/inbox/Tests-jr.364.mcz

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

Name: Tests-jr.364
Author: jr
Time: 12 February 2017, 4:47:21.961498 pm
UUID: d667c4fa-e933-2046-bd88-4a35137490dd
Ancestors: Tests-jr.363

add a Trait to the Monticello test mocks

so a Trait is included in all tests that operate on the mockPackage

=============== Diff against Tests-jr.363 ===============

Item was changed:
  ----- Method: MCMockPackageInfo>>classNames (in category 'as yet unclassified') -----
  classNames
  ^ #( MCMockClassA
  MCMockASubclass
  MCMockClassB
  MCMockClassD
  MCMockClassE
  MCMockClassF
  MCMockClassG
  MCMockClassH
  MCMockClassI
+ MCMockTraitA
  )!

Item was changed:
  ----- Method: MCMockPackageInfo>>classes (in category 'as yet unclassified') -----
  classes
  ^ self classNames
+ select: [:name | Environment current hasClassOrTraitNamed: name]
+ thenCollect: [:name | Environment current at: name]!
- select: [:name | Smalltalk hasClassNamed: name]
- thenCollect: [:name | Smalltalk at: name]!

Item was added:
+ Trait named: #MCMockTraitA
+ uses: {}
+ category: 'Tests-Monticello-Mocks'!
+
+ !MCMockTraitA commentStamp: 'jr 2/11/2017 17:40' prior: 0!
+ This is the comment for a mock trait.!


Reply | Threaded
Open this post in threaded view
|

Re: The Inbox: Tests-jr.364.mcz

Jakob Reschke
Uses #hasClassOrTraitNamed: from Environments-jr.70

Some might wonder whether answering Traits from messages with only
"class" in their name makes sense. The reason is that
PackageInfo>>classes includes Traits as well.

Actually, PackageInfo does not check the type of the things it
collects from an organization at all (except that these things must
respond to #className, or an error will be raised).

2017-02-12 16:56 GMT+01:00 [hidden email]
<[hidden email]>:

> A new version of Tests was added to project The Inbox:
> http://source.squeak.org/inbox/Tests-jr.364.mcz
>
> ==================== Summary ====================
>
> Name: Tests-jr.364
> Author: jr
> Time: 12 February 2017, 4:47:21.961498 pm
> UUID: d667c4fa-e933-2046-bd88-4a35137490dd
> Ancestors: Tests-jr.363
>
> add a Trait to the Monticello test mocks
>
> so a Trait is included in all tests that operate on the mockPackage
>
> =============== Diff against Tests-jr.363 ===============
>
> Item was changed:
>   ----- Method: MCMockPackageInfo>>classNames (in category 'as yet unclassified') -----
>   classNames
>         ^ #(    MCMockClassA
>                         MCMockASubclass
>                         MCMockClassB
>                         MCMockClassD
>                         MCMockClassE
>                         MCMockClassF
>                         MCMockClassG
>                         MCMockClassH
>                         MCMockClassI
> +                       MCMockTraitA
>                 )!
>
> Item was changed:
>   ----- Method: MCMockPackageInfo>>classes (in category 'as yet unclassified') -----
>   classes
>         ^ self classNames
> +               select: [:name | Environment current hasClassOrTraitNamed: name]
> +               thenCollect: [:name | Environment current at: name]!
> -               select: [:name | Smalltalk hasClassNamed: name]
> -               thenCollect: [:name | Smalltalk at: name]!
>
> Item was added:
> + Trait named: #MCMockTraitA
> +       uses: {}
> +       category: 'Tests-Monticello-Mocks'!
> +
> + !MCMockTraitA commentStamp: 'jr 2/11/2017 17:40' prior: 0!
> + This is the comment for a mock trait.!
>
>