diff --git a/gdb-port/tests/unit/ast.py b/gdb-port/tests/unit/ast.py
index 90a448060d40a49fb4e22a0d84351b5f415d78ba..0e2a9d59b92366c012d96ddae6668c1550c79955 100644
--- a/gdb-port/tests/unit/ast.py
+++ b/gdb-port/tests/unit/ast.py
@@ -23,9 +23,34 @@ class HParseResultCreation(unittest.TestCase):
 
 	#TODO: Mocking the read_member method might be needed
 	#TODO: MagicMock breaks self.token_type comparison
+	#TODO: mock read_AST_not_null() to return true
 	def test_make_HParsedToken(self):
 		gdbv_patcher = unittest.mock.patch('gdb.Value', autospec=True)
+		hpt_patcher = unittest.mock.patch('__main__.HParsedToken', autospec=True)
+		hpr_patcher = unittest.mock.patch.object(HParseResult, 'read_AST_not_null', return_value=True)
 		gdbv_patcher.start()
+		hpt_patcher.start()
+		hpr_patcher.start()
 		hpr = HParseResult(0xdeadbeef)
 		tok = hpr.make_HParsedToken()
+		hpr_patcher.stop()
+		hpt_patcher.stop()
 		gdbv_patcher.stop()
+		#TODO: what are the invariants we need to test here?
+		# e.g.: tok.address = hpr.ast.value
+		self.assertEqual(tok.address, hpr.ast)
+
+	def test_make_HParsedToken_if_no_ast(self):
+		gdbv_patcher = unittest.mock.patch('gdb.Value', autospec=True)
+		hpt_patcher = unittest.mock.patch('__main__.HParsedToken', autospec=True)
+		hpr_patcher = unittest.mock.patch.object(HParseResult, 'read_AST_not_null', return_value=False)
+		gdbv_patcher.start()
+		hpt_patcher.start()
+		hpr_patcher.start()
+		hpr = HParseResult(0xdeadbeef)
+		tok = hpr.make_HParsedToken()
+		hpr_patcher.stop()
+		hpt_patcher.stop()
+		gdbv_patcher.stop()
+		self.assertIsNone(tok)
+