Class WeldAppExtension<C extends io.dropwizard.Configuration>

  • 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.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.Configuration>
    • Constructor Summary

      Constructors 
      Constructor Description
      WeldAppExtension​(java.lang.Class<? extends io.dropwizard.Application<C>> applicationClass, C configuration)  
      WeldAppExtension​(java.lang.Class<? extends io.dropwizard.Application<C>> applicationClass, java.lang.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 Detail

      • WeldAppExtension

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

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