Skip to content

Commit

Permalink
fix unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
mam10eks committed Dec 23, 2024
1 parent 46d2070 commit 5ef53f5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
5 changes: 2 additions & 3 deletions test/test_python_script.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import importlib
import json
import os
import shutil
Expand All @@ -12,8 +11,8 @@

from approvaltests import verify_as_json

ROOT_DIR = importlib.resources.files()
TEST_RESOURCES = ROOT_DIR / "test-resources.zip"
ROOT_DIR = Path(__file__).parent.parent.resolve()
TEST_RESOURCES = ROOT_DIR / "test" / "test-resources.zip"


@contextmanager
Expand Down
3 changes: 1 addition & 2 deletions test/test_utility_functions.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
import importlib
import unittest
from pathlib import Path

from git import InvalidGitRepositoryError

from autometadata import _executed_file_from_stacktrace, collect_git_repo_metadata, get_gpu_info

ROOT_DIR = importlib.resources.files() / ".."
ROOT_DIR = Path(__file__).parent.parent.resolve()


class TestUtilityFunctions(unittest.TestCase):
Expand Down

0 comments on commit 5ef53f5

Please sign in to comment.