I released new version of mock objects framework named Mocketry. It is renamed, cleanup and improved BehaviorMockup framework.<br><br>Short review:<br><p>Mocketry is smalltalk mock object framework based on specifications.</p>
<p>It support all kind specifications for object interactions:</p><ul><li> arguments constraint</li><li> context specs</li><li> actions</li><li> usage specs</li><li> ordering messages.</li></ul><p>Behavior specs build by pure message sends to mock objects and has full refactoring support.</p>
<p>Mock objects implements some special proxy mechanizm for support development tools (debugging).</p><p>Mocketry
implements &quot;scenario system&quot; that allows transparent access to mock
objects. If you need mock object just get it in scenario block argument:</p><pre>[:mockA :mockB |<br>        &quot;some set up code&quot;<br><br>        [mockA someMessageWith: 20.<br>        mockB someMessage2] <br>                should strictly satisfy:  <br>
        [mockA someMessageWith: (Kind of: Integer).<br>        mockB someMessage2 willReturn: #someValue].<br><br>        &quot;maybe some assertions: <br>                var should be: true. <br>                ... &quot;<br>] runScenario<br></pre><p>First block here is tested behavior. Second  - expected message sends.</p>
<p>Or
you can create MockObject instance variable in setUp method: &quot;some :=
MockObject new&quot;. And you get mock object named &#39;some&#39; in your &quot;scenario
tests&quot;.</p><p>Mocketry provide special SSpec-like extended DSL based on pragmas for all kind of specifications (state and behavior).</p><pre>10 should be an instance of: SmallInteger<br>[ZeroDivide raiseSignal] should raise: ZeroDivide.<br>
...<br>[mockA someMessage] should lenient satisfy: [mockA someMessage]<br>...<br></pre><p>See squeaksource wiki <a href="http://www.squeaksource.com/Mocketry.html">http://www.squeaksource.com/Mocketry.html</a></p>