-
Trouble executing with stubs
I've made a couple of stubs using the "Lesson 15: Configuring Stub Behavior in Source Code" chapter in "C++test Host-Based Unit Testing" guide. After running "Collect Stub Information" I created User Stubs for the functions I needed to stub. Trying to execute my test case give the error: function…
-
Running SA & UT to cover conditionally compiled code
I am trying to figure out the best solution for running static analysis and unit tests on all of our C++ code. There are 3 different pieces of hardware that our code runs on. We have sections of our code that are compiled out depending on name we pass in to the compiler, IE: “-DHW1”. This is the primary way our main…
-
Define Multiple Stub Callback Functions in a Single File?
Hello, I'm trying to use stubs with Dynamics Stubs Configuration enabled. All the stubs are created using "Create User Stub" option, and each are in Cpptest_Stub_(functionName).cpp files. The user manual stated that I should put Stub Callback functions in test suite files and define the stub logic there. However, instead…
-
C/C++ Test Does not start.
While starting CppTest , it hangs and does not start. Loading process stops while loading some svn or mylyn related plugins. This happens frequently. We have to uninstall and reinstall the software in order to work again.
-
"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,…
-
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.
-
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…
-
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?
-
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…
-
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…
-
-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…
-
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.
-
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…
-
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.
-
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…
-
Report Count and GUI Count Inconsistent
I am running Static Analysis across an entire workspace worth of projects with some key characteristics: Eclipse: Kepler Parasoft: 10.3.4 Number of Projects: ~160 Number of Files: ~ 1000 .c/.cpp and ~1000.h Configuration Properties: 1. Limit is not set on number of violations per rule 2. Check box for "static/Flow Analysis…
-
Parasoft Static Analysis Jobs are Inconsistent
Hello, I am running Static Analysis across an entire workspace worth of projects with some key characteristics: Eclipse: Kepler Parasoft: 10.3.4 Number of Projects: ~160 Number of Files: ~ 1000 .c/.cpp and ~1000.h Configuration Properties: 1. Limit is not set on number of violations per rule 2. Check box for "static/Flow…
-
Inconsistencies in Counting Inside Static Analysis Report
Hello, I am running Static Analysis across an entire workspace worth of projects with some key characteristics: Eclipse: Kepler Parasoft: 10.3.4 Number of Projects: ~160 Number of Files: ~ 1000 .c/.cpp and ~1000.h Configuration Properties: 1. Limit is not set on number of violations per rule 2. Check box for "static/Flow…
-
Error reading test log for Test unit for selected sources.
I build my unit test from eclipse base ide ds5 (Build test executable - generic embedded system ) then ı take ' test log for Test unit for selected sources' error. How can I Solve this problem? Could you give me quickly answer? Thanks
-
Error reading test log for Test unit for selected sources.
I build my unit test from eclipse base ide ds5 (Build test executable - generic embedded system ) then ı take ' test log for Test unit for selected sources' error. How can I Solve this problem? Could you give me quickly answer? Thanks
-
Default host-based unit testing with DS5
Hi, I have no embbedded support feature that is my license does not contain this feature. Therefore I want to run my unit test via "Default host-based unit testing" option which is shown in the attacehed DSC_0103 image. Firstly I create autogenerated unit tests. then I want to run them. When test file is excluded from the…
-
Line suppression in the source code
When we want to suppress a violation in the source code, is it okay to add a comment '// parasoft-suppress...' that is "not" in continuation to the line we want to suppress? Can we insert the comment on top or split it in multiple lines, for the suppression to work? The reason I ask this is because we use a tool that…
-
Should we check for a return statement for void function? Is this critical and affects the quality?
Similar to AUTOSAR rule A8_4_2-a (All exit paths from a function with non-void return type shall have an explicit return statement with an expression), should we also check for a return statement for void function? Is this critical and affects the quality?
-
Disable Static Analysis violation to 1000
Hi , Today when we scan to Parasoft with MISRA C 2012 Rules , we have a limit of 1000 Violations. How can remove the limit ? Thanks :) Chen
-
Is it possible to ignore compilation flags that block (try-catch)
Hi, C++Test 10.4.1. IAR compiler. Is it possible to ignore compilation flag that ignores blocking try-catch flag. Is it possible to writes rules that ignore such blocking try-catch flag. Thanks
-
Can Flow Analysis be performed across multiple Eclipse projects?
The project code (C/C++) is structured into multiple projects. To create the program, 1 very small project is the executable and that links to a number static libraries. The libraries then reference each other. The Flow Analysis will flag many "function is not used in the testing scope" errors as, apparently, the scope…
-
Different result outputs while running Unit Test on full project
When we run a Unit Test by selecting our project in Eclipse it generate different result for each run cycle. e.g. sometime ‘Function A’ is reported to be failed and sometimes ‘Function B’. We have fairly large codebase and it's all C/C++ code for ARM platform.
-
Code coverage on static library
Hello, I'm working with Parasoft C++test 9.5. I have two projects: -one to build a static library -one to build a main program to be linked with the static library I succeeded to do code coverage on the main program only, but I don't know how to do code coverage on the static library as well... How should the static…
-
Violation Report
Hello every one, i need one help while generating the report for static analysis. i ran the static analysis with MISRA C 2012 safety standard compliance rule :-it reported 2025 violation. while i have imported the .BDF file of same source code then i ran the static analysis then it reported 2030 violation. i checked both…
-
.bdf file creation.
how to create bdf file in parasoft c/c++ test 10.4. i am not able to understand also i refer the user guide. so anyone please help me on the same with example. i had run the following command but i am getting error. [princekumar@localhost src]$ cpptesttrace…
-
Stubbing out Internal Functions inside Static Library
My code under test calls another function, I'll call function A. Function A lives in a linked in static library called SL. Function A inside SL calls Function B directly which also lives in SL. I want to stub the call to function B. In this configuration, is this possible? In more general terms, can I stub an internal…
-
Stubbing Fails to Find Functions
I ran the "Collect Stub Information" Built-In test configuration on a project. Inside this project, there are a series of both static and non-static functions. However, when I run that test configuration, it fails to find any non-static symbols (functions). What, if anything in terms of code or project configurations,…