title: Python os.environ.__getitem__ raise KeyError from None
body: <p>Trying to run a python test for an AWS Lamdba Function. The test code will not run and outputs this error</p>
  <pre><code>Traceback (most recent call last):
    line 4, in &lt;module&gt;
    File &quot;/home/ordep81/Documents/cloud-challenge/Lambda/app.py&quot;, line 7, in &lt;module&gt;
      region_name = os.environ['REGION_NAME']
    File &quot;/usr/lib/python3.8/os.py&quot;, line 673, in __getitem__
    raise KeyError(key) from None
  </code></pre>
  <p>Here is the code initializing the variable app.py :</p>
  <pre><code>import boto3
  import json
  import os
  
  # create the client outside of the handler
  region_name = os.environ['REGION_NAME']
  dynamo = boto3.client('dynamodb')
  table_name = os.environ['TABLE_NAME']
  </code></pre>
  <p>Code running the test test_app.py</p>
  <pre><code>import boto3
  import os
  import unittest
  from app import lambda_handler
  from moto import mock_lambda
  </code></pre>