Instinct 0.1.6 Release
I’m happy to announce the release of Instinct 0.1.6. Thanks to all our new users and especially to the guys at VLC & SAP who’ve helped us apply Instinct in anger, and Sanjiv, who’s come on board with development.
Downloads are available from the project site.
This release includes a raft of updates, most notably auto-creation of specification doubles (mocks, stubs & dummies), automatic reset and verification of mocks, a cleanup of the state-based expectation API, fixes for Eclipse JUnit integration, custom classpath support in the Ant task and inherited contexts.
Here’s the full list of updates:
Core
- Remove the need for @Context annotation.
- Automatic creation of specification doubles: mocks, stubs and dummies.
- Automatic reset and verification of mocks.
- @BeforeSpecification?, @AfterSpecification?, @Specifications (and naming convention equivalents) can be used across base and subclasses.
Expectation API
- Make expectations more like natural language. eg. isEqualTo(), doesNotEqual(), etc. Existing code using equalTo(), etc. will need to be updated.
- Collection checkers: hasTheSameContentAs(Collection
) and hasTheSameContentAs(E…). These only check content and not the order of elements. - Ensure all “collection” classes (Array, Map, Set, List, String, SharSequence?) have similar size checkers available.
- Added file checker
- Better error messages for hasBeanProperty and hasBeanPropertyWithValue.
JUnit integration
- Fix Eclipse unrooted context.
Ant integration
- Support for custom classpath.
- Quiet specification result formatting (only shows errors and pending specs).
- Use correct project logging level for errors, etc.
jMock integration
- Support states: Mockery.states(String).
Infrastructure
- Removed reliance on Boost, transferred all relevant Boost classes locally.
- jMock 2.4.
- Downgraded to CGLib 2.1.3 (for Maven integration).
Bugs
- Miscellaneous NullPointerExceptions? and null related problems in state expectation API.
- (defect-3) IterableChecker? should have a containsOnly method or something.
- (defect-8) @BeforeSpecification? does not run if implemented in an abstract base class.
- (defect-20) CEclipse Junit4 InstinctRunner? shows tests under the “Unrooted Tests” node.
- (defect-22) Context treeview shows baseclass and subclass when only subclass is run.
- (defect-23) Overridden specifications run twice.