joel-costigliola/assertj-core-java8 — pull request #10 by jcgay (2014-08-03 20:46:14+00:00)
Title: Initial experimentation for testing Exception

This is a not a pull-request to merge.

I just want to get feedback before going further.
I'd really like to have a way to express test dealing with `Exception` without using JUnit Rule or Proxy things (like `CatchException`). There is an open issue on `assertj-core` [here](https://github.com/joel-costigliola/assertj-core/issues/94).

For now, I have write something like :

assertThat(() -> Arrays.asList(1).get(2))
.willThrow(IndexOutOfBoundsException.class)
.hasMessage("Something goes wrong !");

But I don't really like the api, in this state I would need to wrap `ThrowableAssert` to have methods like `withMessage` instead of `hasMessage`, it's doable but I'm not sure that defining a `assertThat` method with a `FunctionalInterface` as parameter is a good idea.
If we imagine other usage involving `FunctionalInterface` it could lead to overloading problems.

Maybe I can come with another entry point to start the assertions,

assertThatThrowableThrownBy(() -> Arrays.asList(1).get(2))
.isInstanceOf(IndexOutOfBoundsException.class)
.hasMessage("Something goes wrong !");

WDYT ?