move setExpectedException directly before the tested method
move setExpectedException directly before the tested method

sonata-project/SonataCoreBundle,sonata-project/SonataCoreBundle,sonata-project/SonataCoreBundle,sonata-project/SonataCoreBundle