Skip to content

GitHub Action to run cpptestcli from Parasoft C/C++test Professional

Notifications You must be signed in to change notification settings

spacecubics/action-cpptestcli

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 

Repository files navigation

Run cpptestcli from Parasoft C/C++test

This action runs cpptestcli from Parasoft C/C++test Professional.

Parasoft already provides an official GitHub Action, run-cpptest-action. If you prefer the official one, please visit their repository.

action-cpptestcli aims not to interfere with cpptestcli. It behaves just as cpptestcli does. For example, if you specify a .bdf, it creates projects from the .bdf. If you specify config, it will generate a report.

One difference from cpptestcli is that it always passes -data. The default value for -data is workspace. This is because, unlike desktop usage, action-cpptestcli is used for CI, and users don’t want to interact with ~/parasoft/workspace/. Instead, it should use a temporary workspace for CI.

Another difference is that -report is also always passed. The default value for -report is report. The report is generated under the report/ directory.

Basic usage

- name: Run cpptestcli
  uses: spacecubics/action-cpptestcli@v1
  with:
    settings: local.conf
    bdf: cpptestscan.bdf
    config: builtin://Recommended Rules

This will run cpptestcli in the current working directory, create workspace/, apply ./local.conf, loads and generates projects from ./cpptestscan.bdf in the workspace, then generate a report using the build in “Recommended Rules” under report/ directory.

Scenarios

cpptestcli is not in PATH

- name: Run cpptestcli
  uses: spacecubics/action-cpptestcli@v1
  with:
    settings: local.conf
    bdf: cpptestscan.bdf
    config: builtin://Recommended Rules
    install-dir: /opt/tools/cpptest-2023.2.0

If you don’t have cpptestcli, you can specify install-dir.

Different workspace directory

- name: Run cpptestcli
  uses: spacecubics/action-cpptestcli@v1
  with:
    settings: local.conf
    bdf: cpptestscan.bdf
    config: builtin://Recommended Rules
    data: myworkspace

Different report directory

- name: Run cpptestcli
  uses: spacecubics/action-cpptestcli@v1
  with:
    settings: local.conf
    bdf: cpptestscan.bdf
    config: builtin://Recommended Rules
    report: myreport

Create projects from a .bdf file but not generate report

- name: Run cpptestcli
  uses: spacecubics/action-cpptestcli@v1
  with:
    settings: local.conf
    bdf: cpptestscan.bdf

Resource to use within the workspace

- name: Run cpptestcli
  uses: spacecubics/action-cpptestcli@v1
  with:
    settings: local.conf
    bdf: cpptestscan.bdf
    config: builtin://Recommended Rules
    resource: myproject

Generate report from already populated workspace

- name: Run cpptestcli
  uses: spacecubics/action-cpptestcli@v1
  with:
    settings: local.conf
    config: builtin://Recommended Rules

Run cpptestcli in a different directory

- name: Run cpptestcli
  uses: spacecubics/action-cpptestcli@v1
  with:
    settings: local.conf
    bdf: cpptestscan.bdf
    config: builtin://Recommended Rules
    working-directory: builddir

Specify multiple configuraion files

- name: Run cpptestcli
  uses: spacecubics/action-cpptestcli@v1
  with:
    settings: local.conf:license.conf
    bdf: cpptestscan.bdf
    config: builtin://Recommended Rules
    working-directory: builddir

About

GitHub Action to run cpptestcli from Parasoft C/C++test Professional

Resources

Stars

Watchers

Forks

Packages

No packages published