MockDomain serviceDomain = new MockDomain();
deployment.init(serviceDomain, ActivatorLoader.createActivators(serviceDomain));
// Grab a reference to our activators
MockActivator activator = (MockActivator)
deployment.findActivator(MockBindingModel.TYPE);
deployment.start();
deployment.stop();
deployment.destroy();
// Verify the activators were poked
Assert.assertTrue(activator.activateServiceCalled());
Assert.assertTrue(activator.activateBindingCalled());
Assert.assertTrue(activator.startCalled());
Assert.assertTrue(activator.stopCalled());
Assert.assertTrue(activator.deactivateServiceCalled());
Assert.assertTrue(activator.deactivateBindingCalled());
}