From 713bcf2f69289a61f17bdba7746cf35666bb455e Mon Sep 17 00:00:00 2001 From: Alexandre Detiste Date: Thu, 4 Apr 2024 18:22:05 +0200 Subject: [PATCH] use the new unittest.mock as integrated in the standard library --- .github/workflows/python-package.yml | 2 +- test-requirements.txt | 1 - tests/test_cache.py | 2 +- 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/python-package.yml b/.github/workflows/python-package.yml index 4901fa9..1c58bb8 100644 --- a/.github/workflows/python-package.yml +++ b/.github/workflows/python-package.yml @@ -26,7 +26,7 @@ jobs: - name: Install dependencies run: | python -m pip install --upgrade pip - python -m pip install flake8 pytest mock + python -m pip install flake8 pytest python -m pip install -e . if [ -f requirements.txt ]; then pip install -r requirements.txt; fi - name: Lint with flake8 diff --git a/test-requirements.txt b/test-requirements.txt index 3368623..8ef0917 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -1,2 +1 @@ pytest<5 -mock<3 diff --git a/tests/test_cache.py b/tests/test_cache.py index cc004f4..776962e 100644 --- a/tests/test_cache.py +++ b/tests/test_cache.py @@ -1,6 +1,6 @@ import json import os -import mock +from unittest import mock import unittest from pathlib import Path