Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Latest commit

 

History

History
37 lines (23 loc) · 1.58 KB

File metadata and controls

37 lines (23 loc) · 1.58 KB

unit-test-tutorial

Quick Tutorial for using JUnit to create unit tests. This is a template project built by Matthew Lalmansingh. It has some base configurations built in to make it easier to start writing useful code.

Open in an IDE

If you are using IntelliJ IDEA < 13.1, skip to the instructions below.

  1. Open command prompt/terminal and navigate to root folder of the project
  2. Run the command gradlew idea. If in Bash terminal, ./gradlew idea.
  3. After you see BUILD SUCCESSFUL you can open the project in your IDE

IntelliJ 13.1

More recent versions of IntelliJ IDEA have better support for importing Gradle projects. Simply use the Import Project menu option in IntelliJ and you will be good to go.

Validating Gradle Import

After you run the Gradle Command above,you need to validate your dependency imports.

  1. Run the command gradlew test.
  2. Import was successful if you see BUILD SUCCESSFUL

The Gradle Wrapper

The Gradle wrapper is the recommended method for running a Gradle build. A Gradle wrapper script (gradlew.bat/sh) is already included in your project. See the docs for info about upgrading the Gradle version that your project uses.

You can also install Gradle on your machine for use outside of your project.

Technologies