Changes between Version 64 and Version 65 of ProgrammingGuidelines


Ignore:
Timestamp:
07/03/14 14:02:48 (5 years ago)
Author:
welberge
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • ProgrammingGuidelines

    v64 v65  
    259259}}} 
    260260 
     261Assert that someList has an item of class X. 
     262import static org.hamcrest.CoreMatchers.instanceOf; 
     263import static org.hamcrest.MatcherAssert.assertThat; 
     264import static org.hamcrest.Matchers.hasItemInArray; 
     265... 
     266{{{ 
     267assertThat(someList.toArray(), hasItemInArray(instanceOf(X.class)));         
     268}}} 
     269 
    261270=== Mocking === 
    262271TODO: some simple examples