From 72eca2f8e82f1af20e433218719d99e7627d5650 Mon Sep 17 00:00:00 2001 From: Bert JW Regeer Date: Mon, 4 May 2020 00:14:30 -0700 Subject: Fix tests that depend on the test runner --- tests/test_path.py | 4 ++-- tests/test_util.py | 3 +-- 2 files changed, 3 insertions(+), 4 deletions(-) (limited to 'tests') diff --git a/tests/test_path.py b/tests/test_path.py index 384460fb1..c9cfde2b6 100644 --- a/tests/test_path.py +++ b/tests/test_path.py @@ -101,10 +101,10 @@ class TestCallerPackage(unittest.TestCase): self.assertEqual(result, tests) def test_it_level_3(self): - import unittest + import _pytest result = self._callFUT(3) - self.assertEqual(result, unittest) + self.assertEqual(result, _pytest) def test_it_package(self): import tests diff --git a/tests/test_util.py b/tests/test_util.py index 93493c683..f79cdeb85 100644 --- a/tests/test_util.py +++ b/tests/test_util.py @@ -492,8 +492,7 @@ class Test_object_description(unittest.TestCase): def test_method(self): self.assertEqual( self._callFUT(self.test_method), - 'method test_method of class tests.test_util.' - 'Test_object_description', + 'function tests.test_util.test_method', ) def test_class(self): -- cgit v1.2.3