PROTON-2413: [Python] set PATH in example test runner

Previously the test runner assumed it could find the examples on the
path. This meant that the environment running the examples would have to
set up the path correctly. This is unnecessary as they are all in the
same directory as the test runner itself.
diff --git a/python/examples/test_examples.py b/python/examples/test_examples.py
index 51974cc..5c566b1 100644
--- a/python/examples/test_examples.py
+++ b/python/examples/test_examples.py
@@ -17,7 +17,7 @@
 # under the License.
 #
 
-import re
+import os
 import subprocess
 import time
 import unittest
@@ -27,12 +27,16 @@
 
     # We always use these options
     def __init__(self, args, **kwargs):
+        # Add the module directory to the path to be able to find the examples
+        path = f"{os.path.dirname(__file__)}{os.pathsep}{os.environ['PATH']}"
         super(Popen, self).\
             __init__(args,
                      shell=False,
                      stderr=subprocess.STDOUT,
                      stdout=subprocess.PIPE,
-                     universal_newlines=True, **kwargs)
+                     universal_newlines=True,
+                     env={'PATH': path},
+                     **kwargs)
 
 
 # Like subprocess.run with our defaults but returning the Popen object
@@ -41,6 +45,13 @@
     p.wait()
     return p
 
+
+def check_call(args, **kwargs):
+    # Add the module directory to the path to be able to find the examples
+    path = f"{os.path.dirname(__file__)}{os.pathsep}{os.environ['PATH']}"
+    return subprocess.check_call(args, env={'PATH': path}, **kwargs)
+
+
 class ExamplesTest(unittest.TestCase):
     def test_helloworld(self, example="helloworld.py"):
         with run([example]) as p:
@@ -101,8 +112,8 @@
     def test_db_send_recv(self):
         self.maxDiff = None
         # setup databases
-        subprocess.check_call(['db_ctrl.py', 'init', './src_db'])
-        subprocess.check_call(['db_ctrl.py', 'init', './dst_db'])
+        check_call(['db_ctrl.py', 'init', './src_db'])
+        check_call(['db_ctrl.py', 'init', './dst_db'])
         with Popen(['db_ctrl.py', 'insert', './src_db'], stdin=subprocess.PIPE) as fill:
             for i in range(100):
                 fill.stdin.write("Message-%i\n" % (i + 1))