Using GivenWhenThen Test Fixture with AggregateAnnotationCommandHandler

Hi All,

I could not find any example of using Axon’s GivenWhenThen test fixture with AggregateAnnotationCommmandHandler, is it possible to do so ?

Thanks & Regards,

Setya

Hi All,

I’ve found that we don’t have to specify the command handler, so the following just works:

`
@Before
public void setup()
{

fixture = Fixtures.newGivenWhenThenFixture(MyAggregate.class);
}

`

Please clarify that above code is sufficient.

Thanks & Regards,
Setya

If you have @CommandHandler annotations on your aggregate, this in fact all you need.

Cheers,

Allard

Hi Allard,

Glad to know it’s enough.

Thanks & Regards,

Setya