-
Is there a way to report names of global/static variables?
Is there a way to report names of namespace scope and translation unit static variables?
-
Parasoft support for [[fallthrough]]
Does Parasoft Static Analysis support standard [[fallthrough]] attribute or gcc attribute((fallthrough))? If not, are there plans to support them?
-
how to validate a reference argument on CPPTEST_ON_CALL?
I'm using gcc compiler MinGW version 6.3.0 with Parasoft 10.4 under eclipse. I have a C++ function which expects an argument passed as reference, I want to validate on my test that I'm not passing that argument as null. I tried several ways to use the .Equal() on the stub, but I always get errors. My simplified code is…
-
Parasoft unit test C/C++ test: How to use constant as variable in Unit test
Hello, vehicle software has many special constants which could be changed by test/calibration engineers during tests with calibration tools. While designing unit test cases, I would like to change the value of these test cases across test cases. But since these are defined as constants, one the software is compiled, I…
-
Saving Unit Test in VS 2017 using "Test Case using Editor"
Hello All, Am I missing something -- but in Visual Studio 2017 - when I attempt to create a new unit test using "Test Case using Editor" i do not see any dialog on save. I figured out a work around - by "x"ing out the tab I am prompted to save - -but that does not seem very graceful. Here is a screen shot (also…
-
COMMENT-04 Bug
Hey, As I was customizing a rule set I noticed a bug in COMMENT-04. It seems that if you run it on a directory with files, it works as indicated in the documentation. However, if you run it on a .sln, with multiple sub directories it flags many more (correctly commented) functions. I presume that it has to do with the way…
-
Launch cpptest with a specific workspace and modify PROJECT_LOC variable
Hello, I have two queries. 1). I wish to know how to launch the cpptest GUI and specify a workspace to open rather than the default (not sure where this is set either). 2). How to modify the PROJECT_LOC so that projects can be shared with multiple people. Parasoft is able to pick on the PARENT_LOC and WORKSPACE_LOC based…
-
Is there technical documentation
I'm using C++test in a custom way (embedded ST ARM MCU) and am fatigued by the lack of productivity and progress. The "owners manual" (Parasoft C/C++test Professional) doesn't begin to describe what's really happening with the code. I see how to turn the headlights on and off, but only one works. Now what? Is there any…
-
how to customize METRICS-39 ?
I am trying to create a version of METRICS-39 with a different threshold. I have duplicated the rule and modified the RULEMAP. However when I open the rule in the wizard there doesn't appear to be a way to modify the threshold like other rules. what am I missing?
-
best static analysis rule for arithmetic complexity?
Hello, I have found a few metrics that appear to address operator complexity. Halstead is the metric you find online. It looks like C++test supports several different Halstead complexity calculations but; a. they are not all enabled b. the ones that are enabled are not setup for violation detection. I also found VOCF which…
-
Suitability of Parasoft C/C++ for performing Static Code Analysis
Hi All , My necessity is to evaluate options to consider usage of Parasoft C/C++ for conducting Static code analysis ( i) whether Parasoft C/C++ integrates seamlessly into VS 2015(IDE) , GIT and Jenkins ii) does it involve C++/CLI (Managed C++) for static analysis in addition to languages used C, C++, MFC & C#, .NET iii)…
-
Keil unable to build unit test using library approach
Hello, I am using Keil for our application development. The objective is to create unit tests for our application that will run in the ARMCM4_FP emulator. For unit testing, I created a "UnitTest" build target that creates a library, verses an executable, of the application code and any non-hardware dependent library…
-
Need timeout == pass
Infinite loop timeoutI want C++Test to report a success if timeout is triggered. I have an infinitely looping task. I expect a timeout. I don't want the timeout reported as an error. Here is the basic setup of the function (which I am not free to change) ... void MyInfiniteTask(void) { while (TRUE) {…
-
"Scope Settings" Menu inside Parasoft Project Properties
I looked at your documentation to try to get more information into what these options in this menu do. I found a lot on how to use it, and what each of the options are for, but it did not explain what the impact would be on utilizing these settings? For example, I know that it doesn't run code coverage or static analysis,…
-
BDF working directory
Hi, I created my bdf and everything works as it should. However, i notice in the .bdf file the working directory has an absolute directory, eg working directory = /home/chris/workspace1/projname/ Is there are smart way to update the the .bdf file to have a relative path so if I open my project in a new workspace it will…
-
Unable to generate the Test Suite
Hi Team, I am trying to generate the TestSuite for a .cpp file present in the project. The projects builds fine without any errors. The .out file gets generated. Trying to create as - Right click on the .cpp-> Parasoft -> Test Using -> User Defined -> Unit Testing -> Generate Test Suites. The error displayed in the console…
-
C++test Cpptestcc Advanced Tutorial: Including Static Libraries Coverage
This is a second part to the following forum post: https://forums.parasoft.com/discussion/4423/c-test-latest-coverage-collecting-features#latest This post assumes that you understand how the basic of instrumenting source code for coverage collection via cpptestcc and how to use/build C++test Coverage Runtime libraries. We…
-
Cannot find function
When creating a test case for a function (without processing), the C++ test tool cannot find the target of the corresponding function in the Drop-down menu.
-
Build artifact deployment to AWS EC2
Hi, I am working on a .net application.Output of my msbuild is dll. I want to deploy these dll's from Jenkins to AWS EC2 windows machine using scripted pipeline.What is the better way to do it?I am looking for any suggestions/example docs on this. Thanks, Saisirisha
-
Static Analysis Rule
Hi, I analyse my code with recommended rule set but I noticed the following thing; I can easly detect array out of bound for example; int scores[] {100, 90, 80}; for (int i = 0; i <= scores.size() ; i++) // I take a violation about array out of bound error { ..... } But I have a method which takes transpose of matris. My…
-
C++test latest Coverage Collecting Features
C++test has introduced a new functionality that will allow users to combine all coverage findings from their Static Libraries and/or previous runs into one report. We have introduced a new wrapper executable used to collect coverage, cpptestcc, and introduced a new fully customizable Runtime Coverage Library. I have put…
-
Unable to find "stdlib.h" during stub generation
Hi all, I'm currently working on a modification to some Linux kernel code, and while I've been able to generate a BDF for the entire kernel and can perform static analysis on my new/changed files without a problem, I can't seem to either generate stubs or run unit tests on the affected files (in file scope). For instance,…
-
Working with Wind River Workbench in command line
Hi, We use. Parasoft with jenkins therefore we work in command line. For working with Wind River Workbench project how should we proceed?
-
Remote connections to C++Test and running multiple instances of it by the same user
Dear Sir/Madam I have installed a C++Test on a Windows server. I have one network license (1 licensed token) for this product. Please consider the following scenario: We have configured the windows server to permit multiple remote-connections to it by the same user name but with different sessions. Now, we connect remotely…
-
Static Analysis on isolated module (c-file)
Hello, I have an interest in simply open a module (c-file) into parasoft and executing one of the built-in Static Analysis sets, for example "Example Configurations". Is there any way to do this without creating a full build project and assigning a build system (CDT, microsoft, gcc, etc.) The module is part of a larger…
-
Execution problem for cppunit format tests
Hi, I try to run cppunit format unit test in cpptest standalone ide with armcc compiler. Then I take the attached error. How can I fix it? Then I run the example which is provided from you. Your cppunit test did not work also. Your example was ATM. I took again the same error. The error attached to discussion. And I…
-
Build id - character limit?
Do we have any character limit for the BUILD ID?
-
C++Test, no project import in Visual Studio plugin
Hello, I just installed VS 2017 and the C++Test plugin for visual studio. There appears to be some basic installation issues. * The new Visual Studio launcher to enable C++Test does not appear in my Start Menu * Visual Studio does display the ParaSoft menu * New/Project.../Import Keil Project is missing. Actually all of…
-
Keil uVision Static Analysis Problem
I worked with Keil uVision. For analysing Keil uVision code I followed instruction of the https://docs.parasoft.com/display/CPPDESKE1041/Keil+MDK-ARM+Support document. I create bdf file and I import my code and bdf file to standalone C++test ide. Then I tried to do static analysis for this code. In the parasoft document it…
-
How do you generate stubs for template class functions?
When collecting stub information in my test configuration I am not finding references to our functions in template classes. Is there a way to generate stubs for our template class functions? Here is an example of a template that we are using in another class that is under test. The function func_1 doesn't show up in when…
-
Stubs for variadic functions
Recently I had to stub out a Linux ioctl function for testing. I found that the stub doesn't pass the variadic arguments to the callback function. In order to pass the arguments I made a quick hack, and hijacked the __return pointer from within the auto-generated stub code to be able to see the arguments as shown below. Is…
-
Setup problem for header files
Hi, I have an eclipse C++ project and a configuration for static analysis, I am able to use the configuration file to perform static analysis, and generate a Parasoft C++test Report. However, when i export the configuration file and tried to perform static analysis via the command line (cpptestcli), I encountered setup…
-
-vs switch has to be specified with Visual Studio version problem
We prepare a .bat file and we call this bat file from jenkins. This bat file commands works in Visual Studio command prompt. When I execute these commands individually There have no problem but when I call bat file from normal command prompt We take the "-vs switch has to be specified with Visual Studio version " problem.…
-
Parasoft Warnings Tab
I try to work Parasoft with Jenkins. They are working well each other. But when I call parasoft throughout jenkins, the static analysis and then unit test execution is finished, the Parasoft Warnings Tab in Jenkins interface does not appear. Why this case occur. In the begining of the project creation I select freestyle…
-
Jenkins with slave Linux Virtualbox running cpptestcli
Hi, I have a Jenkins job that will perform a svn checkout to a Linux VirtualBox every day. After checking out, the job will perform a make clean and make all operation, before trying to call the cpptestcli command. The command I ran: cpptestcli \ -data "../" \ -import "ProjectName" \ -config…
-
cpptestcli error:unable to find parasoft test installation
When I want to work command line and try to run static analysis in command line take cpptestcli error:unable to find parasoft test installation error. Related image is added to question.
-
Static Analysis Skipped File
Hi, I run static analysis via command line and I obtain successful result. There have a no error while execution. But I noticed that the Skipped info. What is it? I did not understand the meaning of it. I attached related screen shot to discussion.
-
Create bdf file with Maven
Hi, I can run mvn clean install in command line. Then Itry to generate bdf file for this maven project.But I get an error.The error attached to discussion.Why this error obtain?
-
Parasoft Example Eclipse Project Unit Testing Gcc Problem
I am working with Parasoft ATM eclipse example. First of all I create bdf file for this ATM project. And I open this project in C++Test ide with using bdf file option. I successfully run static analysis and optain results. Then I create aoutogenerated tests via "Generate unit tests" option. Then I run these test. I obtain…
-
Parasoft Findings Plugin in Jenkins integration Error
Hi I had Installed Parasoft C/C++ Test and 'Parasoft Findings Plugin' in our Jenkins server(Ubuntu 16.04.6 LTS). I'd like to display the C/C++ test report that built in Jenkins. I created a new item and filled out the following in the build and post-build action area: When building the item, the following log was printed.…
-
Generate a Report from Persistent Violations for Static Analysis
When I run Static Analysis over my code base using Eclipse, any violations that pop up will be listed under Quality Tasks. Under the Configuration Running tab (or view), at the conclusion of the run, it states how many quality tasks were found, gives me the progress bar, and then at the bottom allows me to generate a…
-
Acccess Project/Workspace Location in cpptest suite
Our current test suite is littered with absolute file paths. This makes our test suites less portable. I'd like to be able to access the workspace and project locations from within our tests. How can I do this? Are there environment variables that contain this information that can be gotten through getenv()? Or are there…
-
plugin un-installation procedure
What is the recommended (vetted) procedure to uninstall a <parasoft_cpptest_desktop_10.x.y_win32_x86_64_eclipse.exe> plugin? I already tried running a formal way from Control Panel > Uninstall a program > double click ... No requests in regards to "Uninstall, Change, or Repair" option, the cycle just removed (most of) the…
-
Keil uVision Static Analysis Quick Start
In this post, I will go over how to get started with using C++test static analysis on Keil uVision projects. In this example, I will be using the C++test example MDK-ARM Sensor project. This can be found within ${CPPTEST_HOME}/Examples/Embedded/MDK-ARM/Sensor. In this post I will use the following: C++test 10.4.2…
-
How to Save Test Suite
We're trying to save a Linux test suite (using git) so we can share it among developers. The existing suite contains several hidden files (.parasoft, .cproject, .project, .metadata) that contain absolute paths to the original suite locations, which breaks badly when we try to reuse the project elsewhere. How can we save…
-
Test execution: error linking test executable for Test unit for selected sources. Error
What is this error, what is the resolution for it? the error "Test execution: error linking test executable for Test unit for selected sources." comes while running the unit tests.
-
Question about "translation unit" in RuleWizard
Hi. We need to use RuleWizard to creat a new rule. The thing we want to do is getting all functions in two or more translation units. Can we do that? If so, how? Thank you for reply.
-
Maven NAR project Parasoft C++Test Integration
We noticed that Jtest and Maven can easly integrated. However we did not find Maven C++Test plugin for native project in Maven. How can we integrate Parasoft C++Test with Maven NAR?
-
Reset RunId inside Dynamic Stubs
I am running Unit Testing in the following environment: Eclipse: Kepler Parasoft: 10.3.4 I am using dynamic stubs to do unit testing. I am calling the same function multiple times inside a single test case, and that function calls additional sub-functions that are stubbed. I know that I can set the Run Ids to control the…
-
Static analysis violation
Hi I run the recommeded rules in c++test. I take a several violation in code. I did not interpret one violation which says 'Value 42 is out of acceptable range' lower than 30'. What does the meaning of it? I did not understand violation. The sreen shot of violation is attached to question.