From e42c3c23fc7ce60b2294307a100167d2b736cd30 Mon Sep 17 00:00:00 2001 From: Eugene Triguba Date: Sun, 6 Feb 2022 05:54:07 -0600 Subject: Fix `taskipy.variables` table name in error message (#39) --- taskipy/task_runner.py | 2 +- tests/test_taskipy.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/taskipy/task_runner.py b/taskipy/task_runner.py index b510eaf..9ebac6d 100644 --- a/taskipy/task_runner.py +++ b/taskipy/task_runner.py @@ -61,7 +61,7 @@ class TaskRunner: try: command = command.format(**self.__project.variables) except KeyError as e: - raise MalformedTaskError(task.name, f"{e} variable expected in [pyproject.taskipy.variables]") + raise MalformedTaskError(task.name, f"{e} variable expected in [tool.taskipy.variables]") if self.__project.runner is not None: command = f'{self.__project.runner} {command}' diff --git a/tests/test_taskipy.py b/tests/test_taskipy.py index e83bf54..6ce63f7 100644 --- a/tests/test_taskipy.py +++ b/tests/test_taskipy.py @@ -504,7 +504,7 @@ class UseVarsTestCase(TaskipyTestCase): ''' cwd = self.create_test_dir_with_py_project_toml(py_project_toml) exit_code, stdout, _ = self.run_task('echo', cwd=cwd) - self.assertSubstr("reason: 'name' variable expected in [pyproject.taskipy.variables", stdout) + self.assertSubstr("reason: 'name' variable expected in [tool.taskipy.variables", stdout) self.assertEqual(exit_code, 1) def test_use_vars_setting(self): -- cgit v1.2.3