Dropwizard Junit runner

A JUnit runner to allow testing of Dropwizard applications

License

License

Categories

Categories

DropWizard Container Microservices JUnit Unit Testing
GroupId

GroupId

io.federecio
ArtifactId

ArtifactId

dropwizard-junit
Last Version

Last Version

0.6
Release Date

Release Date

Type

Type

jar
Description

Description

Dropwizard Junit runner
A JUnit runner to allow testing of Dropwizard applications
Project URL

Project URL

https://github.com/federecio/dropwizard-junit/
Source Code Management

Source Code Management

http://github.com/federecio/dropwizard-junit

Download dropwizard-junit

How to add to project

<!-- https://jarcasting.com/artifacts/io.federecio/dropwizard-junit/ -->
<dependency>
    <groupId>io.federecio</groupId>
    <artifactId>dropwizard-junit</artifactId>
    <version>0.6</version>
</dependency>
// https://jarcasting.com/artifacts/io.federecio/dropwizard-junit/
implementation 'io.federecio:dropwizard-junit:0.6'
// https://jarcasting.com/artifacts/io.federecio/dropwizard-junit/
implementation ("io.federecio:dropwizard-junit:0.6")
'io.federecio:dropwizard-junit:jar:0.6'
<dependency org="io.federecio" name="dropwizard-junit" rev="0.6">
  <artifact name="dropwizard-junit" type="jar" />
</dependency>
@Grapes(
@Grab(group='io.federecio', module='dropwizard-junit', version='0.6')
)
libraryDependencies += "io.federecio" % "dropwizard-junit" % "0.6"
[io.federecio/dropwizard-junit "0.6"]

Dependencies

compile (1)

Group / Artifact Type Version
io.dropwizard : dropwizard-core jar 0.8.0

provided (1)

Group / Artifact Type Version
junit : junit jar 4.11

test (1)

Group / Artifact Type Version
com.jayway.restassured : rest-assured jar 1.7.2

Project Modules

There are no modules declared in this project.

dropwizard-junit

a JUnit TestRunner that allows to load Dropwizard 0.8 resources for testing

NOTE: for Dropwizard 0.7.x compatibility use project version 0.5

License

http://www.apache.org/licenses/LICENSE-2.0

How to use it

  • Add the Maven dependency (now available in Maven Central!)

      <dependency>
          <groupId>io.federecio</groupId>
          <artifactId>dropwizard-junit</artifactId>
          <version>0.6</version>
          <scope>test</scope>
      </dependency>
    

Note: you will need to add the junit dependency to your project

  • Write your tests

      @RunWith(DropwizardJunitRunner.class)
      @DropwizardTestConfig(applicationClass = YourServiceClass.class, yamlFile = "/yourconfig.yaml")
      public class YourTest {
          // cool tests here - your Dropwizard service has been started
      }
    

Contributors

Versions

Version
0.6
0.5