def load(self):
        if os.path.exists(self.path):
            with open(self.path, 'r') as f:
                self.body_labels = collections.OrderedDict(json.load(f))
def test_regex_bad_pattern():
    """Regex error raised immediately when regex input parser is created."""
    assert_raises(re.error, inputs.regex, '[')