ISPN-3951 Make sure TestingUtil.replaceComponent is only called after

mock is fully configured

* Changed tests to make sure the replaced component is configured first

https://issues.jboss.org/browse/ISPN-3951