First step in unit test python
<p>I'm a beginner programmer and i'd like to start writing unit tests.
Here is a simple script to open json files:</p>

<pre><code>import json  
from pprint import pprint

def get_notes_data(file_name):
    try:
        with open(file_name, 'r') as open_file:
            return json.loads(open_file.read(), encoding='utf-8')
    except IOError:
        print "enter the correct path file"

data = get_notes_data('notes_data/notes.json')
pprint(data)
</code></pre>

<p><strong>Can I write a unit test for this little piece of code?</strong></p>