def METHOD_NAME(self):
    weights_before_saving = list(self.learner.model.parameters())[0].clone()
    self.learner.save(TEMP_SAVE_DIR)
    self.learner.reset()
    self.assertFalse(t.equal(weights_before_saving, list(self.learner.model.parameters())[0]),
                     msg="Reset method did not alter model weights")
    self.learner.load(TEMP_SAVE_DIR)
    self.assertTrue(t.equal(weights_before_saving, list(self.learner.model.parameters())[0]),
                    msg="Load did not restore weights properly")
    with open(os.path.join(TEMP_SAVE_DIR, os.path.basename(TEMP_SAVE_DIR) + ".json")) as jsonfile:
        metadata = json.load(jsonfile)
    self.assertTrue(all(key in metadata for key in ["model_paths",
                                                    "framework",
                                                    "format",
                                                    "has_data",
                                                    "inference_params",
                                                    "optimized",
                                                    "optimizer_info"]))
    # Remove temporary files
    try:
        shutil.rmtree(TEMP_SAVE_DIR)
    except OSError as e:
        print(f"Exception when trying to remove temp directory: {e.strerror}")