[TEST] class is bound, but directly as null
Original commit: elastic/x-pack-elasticsearch@5ffd911f75cd9df0aedc81ab58f8db7501516348
@@ -164,8 +164,8 @@ public class MonitoringPluginTests extends MonitoringIntegTestCase {
private void assertServiceIsNotBound(Class<?> klass) {
try {
- internalCluster().getDataNodeInstance(klass);
- fail("should have thrown an exception about missing implementation");
+ // it should be bound, but directly as null
+ assertNull(internalCluster().getDataNodeInstance(klass));
} catch (Exception ce) {
assertThat("message contains error about missing implementation: " + ce.getMessage(),
ce.getMessage().contains("Could not find a suitable constructor"), equalTo(true));
