ExternalId forwardId = ExternalId.of("sec", "fx");
EquitySecurity equity = new EquitySecurity("exch", "excd", "ACME", Currency.USD);
ExternalId region = ExternalId.of("regionScheme", "regionValue");
ZonedDateTime now = ZonedDateTime.now();
FXForwardSecurity fxForward = new FXForwardSecurity(Currency.AUD, 123, Currency.CAD, 321, now, region);
FXOptionSecurity fxOption = new FXOptionSecurity(Currency.AUD, Currency.CAD, 123, 321, new Expiry(now),
now, true, new AmericanExerciseType());
SelectorResolver resolver = mock(SelectorResolver.class);
when(resolver.resolveSecurity(equityId)).thenReturn(equity);
when(resolver.resolveSecurity(forwardId)).thenReturn(fxForward);
when(resolver.resolveSecurity(optionId)).thenReturn(fxOption);