24 lines
888 B
Java
24 lines
888 B
Java
package tc.oc.commons.core.inject;
|
|
|
|
import javax.inject.Singleton;
|
|
|
|
import com.google.inject.AbstractModule;
|
|
import tc.oc.commons.core.configuration.YamlConfiguration;
|
|
import tc.oc.commons.core.exception.ExceptionHandler;
|
|
import tc.oc.commons.core.exception.LoggingExceptionHandler;
|
|
import tc.oc.commons.core.logging.Loggers;
|
|
import tc.oc.commons.core.logging.SimpleLoggerFactory;
|
|
import tc.oc.minecraft.api.configuration.Configuration;
|
|
|
|
/**
|
|
* TODO: Should this be in the test source root? That seems to make it unavailable to downstream modules.
|
|
*/
|
|
public class TestModule extends HybridManifest {
|
|
@Override
|
|
protected void configure() {
|
|
bindAndExpose(Loggers.class).to(SimpleLoggerFactory.class);
|
|
bind(Configuration.class).to(YamlConfiguration.class);
|
|
bindAndExpose(ExceptionHandler.class).to(LoggingExceptionHandler.class).in(Singleton.class);
|
|
}
|
|
}
|