How to run a speed test from command line using speedtest-cli

Running a speed test can be very useful to verify the current state of an internet connection, for example, to verify that our ISP (Internet Service Provider) is respecting the parameters we are paying for, or to diagnose possible problems.

One of the most common ways to check ping, download and upload values is to run a test from the speedtest.net website. The speedtest-cli program let us run the same test from our beloved command line interface.