boumenot: Let me know if this is the style of unit test you were thinking of.
diff --git a/azurelinuxagent/agent.py b/azurelinuxagent/agent.py
index e99f7bed..87ab3c14 100644
--- a/azurelinuxagent/agent.py
+++ b/azurelinuxagent/agent.py
@@ -144,7 +144,7 @@ def main(args=[]):
     if command == "version":
         version()
     elif command == "help":
-        usage()
+        print(usage())
     elif command == "start":
         start(conf_file_path=conf_file_path)
     else:
@@ -228,15 +228,16 @@ def version():
 
 def usage():
     """
-    Show agent usage
+    Return agent usage message
     """
-    print("")
-    print((("usage: {0} [-verbose] [-force] [-help] "
+    s  = "\n"
+    s += ("usage: {0} [-verbose] [-force] [-help] "
            "-configuration-path:<path to configuration file>"
            "-deprovision[+user]|-register-service|-version|-daemon|-start|"
-           "-run-exthandlers]"
-           "").format(sys.argv[0])))
-    print("")
+           "-run-exthandlers|-show-configuration]"
+           "").format(sys.argv[0])
+    s += "\n"
+    return s
 
 def start(conf_file_path=None):
     """

WALA usage prompt lacks of " waagent -show-configuration"
We can perform "waagent -show-configuration" to get current WALA configuration,but "waagent -help"lacks of this usage prompt.
diff --git a/tests/test_agent.py b/tests/test_agent.py
index 51b157dd..95994dba 100644
--- a/tests/test_agent.py
+++ b/tests/test_agent.py
@@ -15,9 +15,7 @@
 # Requires Python 2.4+ and Openssl 1.0+
 #
 
-import mock
 import os.path
-import sys
 
 from azurelinuxagent.agent import *
 from azurelinuxagent.common.conf import *
@@ -168,3 +166,22 @@ class TestAgent(AgentTestCase):
         for k in sorted(configuration.keys()):
             actual_configuration.append("{0} = {1}".format(k, configuration[k]))
         self.assertEqual(EXPECTED_CONFIGURATION, actual_configuration)
+
+    def test_agent_usage_message(self):
+        message = usage()
+
+        # Python 2.6 does not have assertIn()
+        self.assertTrue("-verbose" in message)
+        self.assertTrue("-force" in message)
+        self.assertTrue("-help" in message)
+        self.assertTrue("-configuration-path" in message)
+        self.assertTrue("-deprovision" in message)
+        self.assertTrue("-register-service" in message)
+        self.assertTrue("-version" in message)
+        self.assertTrue("-daemon" in message)
+        self.assertTrue("-start" in message)
+        self.assertTrue("-run-exthandlers" in message)
+        self.assertTrue("-show-configuration" in message)
+
+        # sanity check
+        self.assertFalse("-not-a-valid-option" in message)

pip install -e .
parse_log_pytest
requirements.txt
pyasn1 nose pytest
apt-get update apt-get install -y gcc
3.4
requirements.txt
pytest --no-header -rA --tb=line --color=no -p no:cacheprovider -W ignore::DeprecationWarning
attrs==22.2.0
certifi==2021.5.30
importlib-metadata==4.8.3
iniconfig==1.1.1
nose==1.3.7
packaging==21.3
pluggy==1.0.0
py==1.11.0
pyasn1==0.5.1
pyparsing==3.1.4
pytest==7.0.1
tomli==1.2.3
typing_extensions==4.1.1
-e git+https://github.com/Azure/WALinuxAgent.git@ab261b5f2ed0dfce4dd94adf924e68e0aaff5e7b#egg=WALinuxAgent
zipp==3.6.0

name: WALinuxAgent
channels:
  - defaults
  - https://repo.anaconda.com/pkgs/main
  - https://repo.anaconda.com/pkgs/r
  - conda-forge
dependencies:
  - _libgcc_mutex=0.1=main
  - _openmp_mutex=5.1=1_gnu
  - ca-certificates=2025.2.25=h06a4308_0
  - certifi=2021.5.30=py36h06a4308_0
  - ld_impl_linux-64=2.40=h12ee557_0
  - libffi=3.3=he6710b0_2
  - libgcc-ng=11.2.0=h1234567_1
  - libgomp=11.2.0=h1234567_1
  - libstdcxx-ng=11.2.0=h1234567_1
  - ncurses=6.4=h6a678d5_0
  - openssl=1.1.1w=h7f8727e_0
  - pip=21.2.2=py36h06a4308_0
  - python=3.6.13=h12debd9_1
  - readline=8.2=h5eee18b_0
  - setuptools=58.0.4=py36h06a4308_0
  - sqlite=3.45.3=h5eee18b_0
  - tk=8.6.14=h39e8969_0
  - wheel=0.37.1=pyhd3eb1b0_0
  - xz=5.6.4=h5eee18b_1
  - zlib=1.2.13=h5eee18b_1
  - pip:
      - attrs==22.2.0
      - importlib-metadata==4.8.3
      - iniconfig==1.1.1
      - nose==1.3.7
      - packaging==21.3
      - pluggy==1.0.0
      - py==1.11.0
      - pyasn1==0.5.1
      - pyparsing==3.1.4
      - pytest==7.0.1
      - tomli==1.2.3
      - typing-extensions==4.1.1
      - zipp==3.6.0
prefix: /opt/conda/envs/WALinuxAgent

tests/test_agent.py::TestAgent::test_agent_usage_message
tests/test_agent.py::TestAgent::test_accepts_configuration_path tests/test_agent.py::TestAgent::test_agent_accepts_configuration_path tests/test_agent.py::TestAgent::test_agent_does_not_pass_configuration_path tests/test_agent.py::TestAgent::test_agent_ensures_extension_log_directory tests/test_agent.py::TestAgent::test_agent_get_configuration tests/test_agent.py::TestAgent::test_agent_logs_if_extension_log_directory_is_a_file tests/test_agent.py::TestAgent::test_agent_passes_configuration_path tests/test_agent.py::TestAgent::test_agent_uses_default_configuration_path tests/test_agent.py::TestAgent::test_checks_configuration_path tests/test_agent.py::TestAgent::test_configuration_path_defaults_to_none tests/test_agent.py::TestAgent::test_rejects_missing_configuration_path
azurelinuxagent/agent.py
azurelinuxagent/agent.py