@Override protected DeploymentContext configureDeployment() { return ServletDeploymentContext.builder(new DropwizardTestResourceConfig(configuration)) .initParam(ServletProperties.JAXRS_APPLICATION_CLASS, DropwizardTestResourceConfig.class.getName()) .initParam(DropwizardTestResourceConfig.CONFIGURATION_ID, configuration.getId()) .build(); }
@Override protected final DeploymentContext configureDeployment() { configureProperties(); String joinedPackages = String.join(",", getResourcePackages()) + ",com.cloudera.oryx.lambda.serving"; return ServletDeploymentContext.builder(OryxApplication.class) .initParam("javax.ws.rs.Application", OryxApplication.class.getName()) .contextParam(OryxApplication.class.getName() + ".packages", joinedPackages) .addListener(getInitListenerClass()) .build(); }
@Override protected DeploymentContext configureDeployment() { return ServletDeploymentContext.builder(new DropwizardTestResourceConfig(configuration)) .initParam(ServletProperties.JAXRS_APPLICATION_CLASS, DropwizardTestResourceConfig.class.getName()) .initParam(DropwizardTestResourceConfig.CONFIGURATION_ID, configuration.getId()) .build(); }
/** * Create a new servlet deployment context for a JAX-RS / Jersey application instance. * <p> * The created servlet deployment context will be configured to use default values. * </p> * * @param applicationClass a JAX-RS / Jersey application to be tested. * @return new servlet deployment context instance associated with the JAX-RS / Jersey application to be tested. * * @throws java.lang.NullPointerException in case the {@code applicationClass} is {@code null}. */ public static ServletDeploymentContext newInstance(final Class<? extends Application> applicationClass) { return new Builder(applicationClass).build(); }
/** * Create a new servlet deployment context for a JAX-RS / Jersey application instance. * <p> * The created servlet deployment context will be configured to use default values. * </p> * * @param application a JAX-RS / Jersey application to be tested. * @return new servlet deployment context instance associated with the JAX-RS / Jersey application to be tested. * * @throws java.lang.NullPointerException in case the {@code application} is {@code null}. */ public static ServletDeploymentContext newInstance(final Application application) { return new Builder(application).build(); }
/** * Create a new servlet deployment context for a JAX-RS / Jersey application instance. * <p> * The created servlet deployment context will be configured to use default values. * </p> * * @param application a JAX-RS / Jersey application to be tested. * @return new servlet deployment context instance associated with the JAX-RS / Jersey application to be tested. * * @throws java.lang.NullPointerException in case the {@code application} is {@code null}. */ public static ServletDeploymentContext newInstance(final Application application) { return new Builder(application).build(); }
/** * Create a new servlet deployment context for a JAX-RS / Jersey application instance. * <p> * The created servlet deployment context will be configured to use default values. * </p> * * @param applicationClass a JAX-RS / Jersey application to be tested. * @return new servlet deployment context instance associated with the JAX-RS / Jersey application to be tested. * * @throws java.lang.NullPointerException in case the {@code applicationClass} is {@code null}. */ public static ServletDeploymentContext newInstance(final Class<? extends Application> applicationClass) { return new Builder(applicationClass).build(); }