cxxtestgen command not found
Introduction
When you run more command in linux terminal / console, you get the following error message
cxxtestgen: command not found
or when using sudo you get the following error message
sudo: cxxtestgen: command not found
Solutions to cxxtestgen: command not found
How To Fix cxxtestgen: command not found in Ubuntu / Debian / Kali Linux / Raspbian
In Ubuntu cxxtestgen is provided by cxxtest package.
cxxtest is:
CxxTest is a unit testing framework for C++ that is similar in spirit to JUnit, CppUnit, and xUnit. It provides assertions for checking conditions and classes for defining unit-test cases.
CxxTest is easy to use because it does not require precompiling a CxxTest testing library, it employs no advanced features of C++ (e.g. RTTI) and it supports a very flexible form of test discovery, which simplifies the creation of test drivers. It includes a script that parses C++ files that define unit tests and then generates a C++ test runner. When compiled, the test runner manages the execution of all unit tests in a flexible manner.
To fix this problem, we can install more using the command below.
sudo apt-get -y install cxxtest
This command might take some time to finish depending on your machine internet connection.
You can also use apt command to install cxxtest.
sudo apt -y install cxxtest
Or if you have aptitude installed you can use the following command.
sudo aptitude install cxxtest
Summary
In this tutorial we learn how to fix cxxtestgen command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.