Improve generics on some collection matchers. #29
Improve generics on some collection matchers. #29fbarber wants to merge 1 commit intohamcrest:masterfrom
Conversation
|
I think this will be superseded by our plans for collection-specific factory methods |
|
@sf105 Are those methods available already? I'm running into generics compilation errors with the JDT 3.20 compiler for the following code: List<String> result = ...
assertThat(result, allOf(hasSize(1), hasItems("foo")));The error is: |
|
@fbarber fancy rebasing this from master, as I've got some custom collections matchers, which do similar and would be interested getting richer collection matches into hamcrest. i.e. if the collection is the wrong size then output the collection, so when debugging you can shortcut having to run it yourself and get a start on working out the issue. |
The following classes are no longer parameterized as they don't care what is in the collection they match: - IsArrayWithSize - IsCollectionWithSize - IsIterableWithSize - IsMapWithSize - IsEmptyCollection - IsEmptyIterable
|
Sure. I will update with a rebased version soon. |
|
@nhojpatrick Rebase done. |
|
Going to try and kick start hamcrest, so if you want to get it merged, please rebase from the branch |
9bc653b to
e9f7fc8
Compare
The following classes are no longer parameterized as they don't care what is in
the collection they match: