Skip to content

Commit 9d1ffd6

Browse files
julien-langCopilot
andauthored
SG-39873 Use unittest.mock instead of deprecated mock third party library (shotgunsoftware#53)
* Use unittest.mock instead of deprecated mock third party library * Apply suggestion from @Copilot Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Apply suggestion from @Copilot Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent 85214e9 commit 9d1ffd6

2 files changed

Lines changed: 2 additions & 3 deletions

File tree

tests/run_tests.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010

1111
import os
1212
import sys
13+
import unittest.mock as mock
1314

1415
__file__ = os.path.abspath(__file__)
1516

@@ -21,7 +22,6 @@
2122
sys.path.insert(0, os.path.join(tests_folder, "venv", "Lib", "site-packages"))
2223

2324
import pytest
24-
import mock
2525

2626
# We need to patch a couple of things to make pytest and argparse happy.
2727
# argparse doesn't like it when argv is empty, which is what happens when

tests/test_publisher_hooks.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,7 @@
1212
import contextlib
1313
import logging
1414
import pprint
15-
16-
import mock
15+
import unittest.mock as mock
1716

1817
import sgtk
1918

0 commit comments

Comments
 (0)