def test_load_keyvalue_bad_file_extension(self):
        """Test loading of a key/value pair with a bad file extension"""
        fd, path = tempfile.mkstemp(suffix=".badext")
        try:
            args = ["key", "load", path]
            retcode = self.shell.run(args)
            self.assertEqual(retcode, 1)
        finally:
            os.close(fd)
            os.unlink(path)
Test loading of a key/value pair with a bad file extension
st2client/tests/unit/test_keyvalue.py