This documentation relates to an earlier version of Clover.
View

Unknown macro: {spacejump}

or visit the current documentation home.

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Current »

This page relates to an Early Access Program (EAP) for the next major release of Clover 3.0. Hence, this page's content may change significantly in the lead up to the official release date of Clover 3.0.

This page provides instructions for all available Clover-for-Grails plugin installation options.

The documentation below assumes that you have already installed Grails and have configured your PATH environment variable to point to the bin directory of your Grails installation.

There are three ways to install Clover-for-Grails:

Clover requires a license file in order to run. Once you have installed the Clover-for-Grails plugin, you will need to download and install the Clover license file clover.license. You can generate a 30-day evaluation Clover license file by logging in to https://my.atlassian.com and following the instructions on the site.

After 30 days, you need to purchase a commercial Clover license file from this site to continue running Clover. Refer to the instructions below for installing your Clover license file.

Using with an older version of Grails that Clover does not support?


Clover-for-Grails only supports the version of Grails indicated on the Supported Platforms page. Hence, if your Grails project has been developed using an older version of Grails, you will need to:

  1. Download and install a newer version of Grails that Clover supports.
  2. Update your PATH environment variable to point to the bin directory of the newly installed version of Grails.
  3. Change directory to the root of your Grails project directory.
  4. Run the command:
    grails upgrade
    
    This upgrades your Grails project to the new version of Grails that you just installed.

Installing Clover-for-Grails using the built-in Grails command

To install the Clover-for-Grails plugin using Grails' install-plugin command:

  1. Change directory to the root of your Grails project directory. For example, if you installed the sample Grails project 'petclinic' that is bundled with Grails, you would change directory into <Grails Home Directory>/samples/petclinic

  2. Run the command:
    grails install-plugin clover
    
    Grails will download the Clover-for-Grails plugin and install it into your Grails project.

(warning) If you experience problems using this method, try installing the plugin directly from its web address (below).

Installing Clover-for-Grails from its web address

To install Clover-for-Grails directly from its location on the web:

  1. Change directory to the root of your Grails project. For example, if you installed the sample Grails project 'petclinic' that is bundled with Grails, you would change directory into <Grails Installation Directory>/samples/petclinic

  2. Run the following command, which downloads the Clover-for-Grails plugin from the web address and install it into your Grails project:
    grails install-plugin http://plugins.grails.org/grails-clover/tags/RELEASE_x_y/grails-clover-x.y.zip
    
    Where x and y refer to the latest version of the Clover-for-Grails plugin to be installed. To browse for a different version, just enter this URL up to .../tags/ and use your browser links to navigate to (and download) a different version.

You can also install Clover-for-Grails from its Subversion location on the web:

grails install-plugin https://svn.codehaus.org/grails-plugins/grails-clover/tags/RELEASE_x_y/grails-clover-x.y.zip

Installing Clover-for-Grails from the downloaded plugin installation file

To download the Clover-for-Grails plugin installation file and install it:

  1. Download the Clover-for-Grails plugin from this location:
    http://plugins.grails.org/grails-clover/tags/RELEASE_x_y/grails-clover-x.y.zip
    
    Where x and y refer to the latest version of the Clover-for-Grails plugin to be installed. To browse for a different version, just enter this URL up to .../tags/ and use your browser links to navigate to (and download) a different version.

    (info) Save the file to a location that can be accessed from your Grails project.

  2. Change directory to the root of your Grails project.

  3. Run the command to install the downloaded Clover-for-Grails installation file:
    grails install-plugin /path/to/grails-clover-x.y.zip
    
    Grails will install the downloaded Clover-for-Grails installation file into your Grails project.

Due to the nature of Grails' plugin installation architecture, you will need to install the Clover-for-Grails plugin into each Grails project whose Groovy source code you wish to test with Clover.

Installing the Clover license file

Once you have obtained your 30 day evaluation or commercial clover.license file, you need to install it so that your Clover-for-Grails plugin can acknowledge its existence.

You have the following options for installing the Clover license file clover.license:

Move or copy the clover.license file into this location:

Notes about this option:

The root directory of your Grails project.

  • For e.g. <Grails Installation Directory>/samples/petclinic

This option installs the Clover license file to this Grails project only. You will need to install this file into each of your other Grails projects with the Grails-for-Clover plugin too.

The etc directory within your Grails project.

  • For e.g. <Grails Installation Directory>/samples/petclinic/etc

This is similar to the previous option but 'hides' the clover.license file from the root directory of your Grails project.

Your user home directory.

  • Linux/UNIX/Mac OS X:
    • For e.g. /home/username/ or ~
  • Windows:
    • For e.g. C:\Documents and Settings\Username

This will prevent you having to install the Clover license file into every Grails project on your computer as the license file will apply to every Grails project developed on your computer and login account.

You can also place the clover.license anywhere else that's accessible to the Clover-for-Grails plugin and reference it from either:

RELATED TOPICS

Clover 3.0 Early Access Program
Clover-for-Grails Quick Start Guide

  • No labels