Class WeldAppExtension<C extends io.dropwizard.core.Configuration>

java.lang.Object
io.dropwizard.testing.junit5.DropwizardAppExtension<C>
org.sdase.commons.server.weld.testing.WeldAppExtension<C>
All Implemented Interfaces:
io.dropwizard.testing.junit5.DropwizardExtension, org.junit.jupiter.api.extension.AfterAllCallback, org.junit.jupiter.api.extension.BeforeAllCallback, org.junit.jupiter.api.extension.Extension

public class WeldAppExtension<C extends io.dropwizard.core.Configuration> extends io.dropwizard.testing.junit5.DropwizardAppExtension<C>
An App Rule that uses WELD to inject the application class.

Example usage:

   @RegisterExtension
   static final WeldAppExtension<AppConfiguration%gt APP =
       new WeldAppExtension<>(WeldExampleApplication.class, resourceFilePath("test-config.yaml"));
 
  • Nested Class Summary

    Nested classes/interfaces inherited from class io.dropwizard.testing.junit5.DropwizardAppExtension

    io.dropwizard.testing.junit5.DropwizardAppExtension.ServiceListener<T extends io.dropwizard.core.Configuration>
  • Constructor Summary

    Constructors
    Constructor
    Description
    WeldAppExtension(Class<? extends io.dropwizard.core.Application<C>> applicationClass, C configuration)
     
    WeldAppExtension(Class<? extends io.dropwizard.core.Application<C>> applicationClass, String configPath, io.dropwizard.testing.ConfigOverride... configOverrides)
     
  • Method Summary

    Methods inherited from class io.dropwizard.testing.junit5.DropwizardAppExtension

    addListener, after, afterAll, before, beforeAll, client, clientBuilder, getAdminPort, getApplication, getConfiguration, getEnvironment, getLocalPort, getObjectMapper, getPort, getTestSupport, manage, newApplication

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • WeldAppExtension

      public WeldAppExtension(Class<? extends io.dropwizard.core.Application<C>> applicationClass, @Nullable String configPath, io.dropwizard.testing.ConfigOverride... configOverrides)
    • WeldAppExtension

      public WeldAppExtension(Class<? extends io.dropwizard.core.Application<C>> applicationClass, C configuration)