Skip to content

Commit

Permalink
unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
hoefler02 committed Apr 14, 2021
1 parent df34985 commit 908db30
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions tests/runtests.py
Expand Up @@ -518,6 +518,21 @@ def test_cmd_highlight(self):
self.assertIn("\x1b[35m44444444\x1b[0m", res)
return

def test_cmd_aliases(self):
# test add functionality
add_res = gdb_start_silent_cmd("aliases add a b")
self.assertNoException(add_res)
# test list functionality
list_res = gdb_start_silent_cmd("aliases list")
self.assertNoException(list_res)
self.assertIn("a → b", list_res)
# test rm functionality
rm_res = gdb_start_silent_cmd("aliases rm a")
self.assertNoException(rm_res)
rm_list_res = gdb_start_silent_cmd("aliases list")
self.assertNotIn("a → b", rm_list_res)
return


class TestGefFunctions(GefUnitTestGeneric):
"""Tests GEF internal functions."""
Expand Down

0 comments on commit 908db30

Please sign in to comment.