fabriciocolombo / sonar-delphi

SonarQube Delphi Plugin
91 stars 46 forks source link

SonarQube Delphi

Build Status

PayPal donate button

This is the SonarQube Delphi Plugin.

This plugin was originally a Sabre Airline Solutions donation.

Steps to Analyze a Delphi Project

  1. Install SonarQube Server (see Setup and Upgrade for more details). Check supported versions of the latest release of the plugin.
  2. Install one of the supported Runners (see below) and be sure you can call it from the directory where you have your source code
  3. Install Delphi Plugin (see Installing a Plugin for more details).
  4. Check the sample project corresponding to your Runner to know which config file you need to create. You can find the samples in sonar-delphi/samples.
  5. Run your Analyzer command from the project root dir
  6. Follow the link provided at the end of the analysis to browse your project's quality in SonarQube UI (see: Browsing SonarQube)

Supported Runners

To run an analysis of your Java project, you can use the following Runners:

Reporting Issues

SonarQube Delphi Plugin uses GitHub's integrated issue tracking system to record bugs and feature requests. If you want to raise an issue, please follow the recommendations below:

Implemented Features

Code Assumptions

DUnit Tests

You should put transformed DUnit xml files to directory specified using parameter sonar.junit.reportsPath. You can specify multiply directories separated by ,. Then all specified directories will be parsed. The path can be either absolute or relative to the project main path. The xml files should be renamed with TEST- prefix, example: dunit.xml -> TEST-dunit.xml. I recommend you to use dunit-extension to handle these details.

Importing into Eclipse

First run the eclipse maven goal:

mvn eclipse:eclipse

The project can then be imported into Eclipse using File -> Import and then selecting General -> Existing Projects into Workspace.