### Question:
DefaultExplicitIndexProvider implements IndexProviders, ExplicitIndexProvider { @Override public IndexImplementation getProviderByName( String name ) { IndexImplementation provider = indexProviders.get( name ); if ( provider == null ) { throw new IllegalArgumentException( "No index provider '" + name + "' found. Maybe the intended provider (or one more of its " + "dependencies) " + "aren't on the classpath or it failed to load." ); } return provider; }  @Override void registerIndexProvider( String name, IndexImplementation index ); @Override boolean unregisterIndexProvider( String name ); @Override IndexImplementation getProviderByName( String name ); @Override Iterable<IndexImplementation> allIndexProviders();  }### Answer:
@Test void throwOnAttemptToGetNonRegisteredProviderByName() { String testProviderName = "d"; assertThrows( IllegalArgumentException.class, () -> provider.getProviderByName( testProviderName ) ); }