How To Install hamcrest on Fedora 36
Introduction
In this tutorial we learn how to install hamcrest
on Fedora 36.
What is hamcrest
Provides a library of matcher objects (also known as constraints or predicates) allowing ‘match’ rules to be defined declaratively, to be used in other frameworks. Typical scenarios include testing frameworks, mocking libraries and UI validation rules.
We can use yum
or dnf
to install hamcrest
on Fedora 36. In this tutorial we discuss both methods but you only need to choose one of method to install hamcrest.
Install hamcrest on Fedora 36 Using dnf
Update yum database with dnf
using the following command.
sudo dnf makecache --refresh
After updating yum database, We can install hamcrest
using dnf
by running the following command:
sudo dnf -y install hamcrest
Install hamcrest on Fedora 36 Using yum
Update yum database with yum
using the following command.
sudo yum makecache --refresh
After updating yum database, We can install hamcrest
using yum
by running the following command:
sudo yum -y install hamcrest
How To Uninstall hamcrest on Fedora 36
To uninstall only the hamcrest
package we can use the following command:
sudo dnf remove hamcrest
hamcrest Package Contents on Fedora 36
/usr/share/doc/hamcrest
/usr/share/doc/hamcrest/README.md
/usr/share/java/hamcrest
/usr/share/java/hamcrest/hamcrest.jar
/usr/share/licenses/hamcrest
/usr/share/licenses/hamcrest/LICENSE.txt
/usr/share/maven-metadata/hamcrest.xml
/usr/share/maven-poms/hamcrest
/usr/share/maven-poms/hamcrest/hamcrest.pom
References
Summary
In this tutorial we learn how to install hamcrest
on Fedora 36 using yum and [dnf]((/fedora/36/dnf/).