def METHOD_NAME(self, mock_load, mock_open, mock_gen):
    mock_open().__enter__.return_value = "mock_file"
    cmds.write_settings(MOCK_SETTINGS["settings"])
    mock_load.assert_called_once()
    self.assertDictEqual(
        MOCK_SETTINGS, mock_gen.mock_calls[0][1][0].tethys_portal_settings
    )