diff --git a/.fmf/version b/.fmf/version deleted file mode 100644 index d00491f..0000000 --- a/.fmf/version +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/.gitignore b/.gitignore index 37bcb45..07770aa 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1 @@ -SOURCES/psutil-5.6.4.tar.gz /psutil-5.6.4.tar.gz diff --git a/gating.yaml b/gating.yaml deleted file mode 100644 index 648918d..0000000 --- a/gating.yaml +++ /dev/null @@ -1,6 +0,0 @@ ---- !Policy -product_versions: - - rhel-9 -decision_context: osci_compose_gate -rules: - - !PassingTestCaseRule {test_case_name: osci.brew-build.tier0.functional} diff --git a/plan.fmf b/plan.fmf deleted file mode 100644 index e6427de..0000000 --- a/plan.fmf +++ /dev/null @@ -1,4 +0,0 @@ -discover: - how: fmf -execute: - how: tmt diff --git a/python-psutil-add-tolerance.patch b/python-psutil-add-tolerance.patch deleted file mode 100644 index 8c41db4..0000000 --- a/python-psutil-add-tolerance.patch +++ /dev/null @@ -1,25 +0,0 @@ -From 4ffbcb458ff0b838f2bfe387b6305c4817e363ae Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Miro=20Hron=C4=8Dok?= -Date: Thu, 15 Apr 2021 17:07:38 +0200 -Subject: [PATCH] Add tolerance to - test_linux.TestSystemVirtualMemory.test_total - -We see this test as very flaky without tolerance in Fedora and CentOS ---- - psutil/tests/test_linux.py | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) - -diff --git a/psutil/tests/test_linux.py b/psutil/tests/test_linux.py -index 0c6d498c8..f5243c2cd 100755 ---- a/psutil/tests/test_linux.py -+++ b/psutil/tests/test_linux.py -@@ -243,7 +243,8 @@ def test_total(self): - # self.assertEqual(free_value, psutil_value) - vmstat_value = vmstat('total memory') * 1024 - psutil_value = psutil.virtual_memory().total -- self.assertAlmostEqual(vmstat_value, psutil_value) -+ self.assertAlmostEqual( -+ vmstat_value, psutil_value, delta=TOLERANCE_SYS_MEM) - - @retry_on_failure() - def test_used(self): diff --git a/python-psutil-skip-tests-in-brew.patch b/python-psutil-skip-tests-in-brew.patch deleted file mode 100644 index b63a842..0000000 --- a/python-psutil-skip-tests-in-brew.patch +++ /dev/null @@ -1,24 +0,0 @@ -diff --git a/psutil/tests/test_linux.py b/psutil/tests/test_linux.py -index c1d0a94..e9914a9 100755 ---- a/psutil/tests/test_linux.py -+++ b/psutil/tests/test_linux.py -@@ -924,6 +924,7 @@ class TestLoadAvg(PsutilTestCase): - @unittest.skipIf(not LINUX, "LINUX only") - class TestSystemNetIfAddrs(PsutilTestCase): - -+ @unittest.skip("Broken in brew") - def test_ips(self): - for name, addrs in psutil.net_if_addrs().items(): - for addr in addrs: -diff --git a/psutil/tests/test_system.py b/psutil/tests/test_system.py -index a55164c..21a04bb 100755 ---- a/psutil/tests/test_system.py -+++ b/psutil/tests/test_system.py -@@ -724,6 +724,7 @@ class TestNetAPIs(PsutilTestCase): - self.assertEqual(psutil.net_io_counters(pernic=True), {}) - assert m.called - -+ @unittest.skip("Broken in brew") - def test_net_if_addrs(self): - nics = psutil.net_if_addrs() - assert nics, nics diff --git a/python-psutil-skip-tests-in-mock.patch b/python-psutil-skip-tests-in-mock.patch deleted file mode 100644 index 93a2e1c..0000000 --- a/python-psutil-skip-tests-in-mock.patch +++ /dev/null @@ -1,134 +0,0 @@ -diff --color -Nur psutil-release-5.8.0.orig/psutil/tests/test_linux.py psutil-release-5.8.0/psutil/tests/test_linux.py ---- psutil-release-5.8.0.orig/psutil/tests/test_linux.py 2020-12-18 16:45:00.000000000 -0800 -+++ psutil-release-5.8.0/psutil/tests/test_linux.py 2021-01-10 15:38:31.104890945 -0800 -@@ -661,14 +661,13 @@ - value = int(value.split('-')[1]) + 1 - self.assertEqual(psutil.cpu_count(), value) - -- @unittest.skipIf(not os.path.exists("/sys/devices/system/cpu"), -- "/sys/devices/system/cpu does not exist") -+ @unittest.skip("Unreliable on mock") - def test_against_sysdev_cpu_num(self): - ls = os.listdir("/sys/devices/system/cpu") - count = len([x for x in ls if re.search(r"cpu\d+$", x) is not None]) - self.assertEqual(psutil.cpu_count(), count) - -- @unittest.skipIf(not which("nproc"), "nproc utility not available") -+ @unittest.skip("Unreliable on mock") - def test_against_nproc(self): - num = int(sh("nproc --all")) - self.assertEqual(psutil.cpu_count(logical=True), num) -@@ -713,7 +712,7 @@ - m.called - - --@unittest.skipIf(not LINUX, "LINUX only") -+@unittest.skip("Unreliable in mock") - class TestSystemCPUCountPhysical(PsutilTestCase): - - @unittest.skipIf(not which("lscpu"), "lscpu utility not available") -@@ -745,7 +744,7 @@ - @unittest.skipIf(not LINUX, "LINUX only") - class TestSystemCPUFrequency(PsutilTestCase): - -- @unittest.skipIf(not HAS_CPU_FREQ, "not supported") -+ @unittest.skip("Unreliable in mock") - def test_emulate_use_second_file(self): - # https://github.com/giampaolo/psutil/issues/981 - def path_exists_mock(path): -@@ -759,7 +758,7 @@ - create=True): - assert psutil.cpu_freq() - -- @unittest.skipIf(not HAS_CPU_FREQ, "not supported") -+ @unittest.skip("Unreliable in mock") - def test_emulate_use_cpuinfo(self): - # Emulate a case where /sys/devices/system/cpu/cpufreq* does not - # exist and /proc/cpuinfo is used instead. -@@ -888,7 +887,7 @@ - self.assertEqual(freq.current, 200) - - --@unittest.skipIf(not LINUX, "LINUX only") -+@unittest.skip("Unreliable in mock") - class TestSystemCPUStats(PsutilTestCase): - - def test_ctx_switches(self): -@@ -2126,13 +2125,14 @@ - value = tuple(map(int, value.split()[1:4])) - self.assertEqual(self.proc.gids(), value) - -- @retry_on_failure() -+ @unittest.skip("Unreliable in mock") - def test_num_ctx_switches(self): - value = self.read_status_file("voluntary_ctxt_switches:") - self.assertEqual(self.proc.num_ctx_switches().voluntary, value) - value = self.read_status_file("nonvoluntary_ctxt_switches:") - self.assertEqual(self.proc.num_ctx_switches().involuntary, value) - -+ @unittest.skip("Unreliable in mock") - def test_cpu_affinity(self): - value = self.read_status_file("Cpus_allowed_list:") - if '-' in str(value): -diff --color -Nur psutil-release-5.8.0.orig/psutil/tests/test_misc.py psutil-release-5.8.0/psutil/tests/test_misc.py ---- psutil-release-5.8.0.orig/psutil/tests/test_misc.py 2020-12-18 16:45:00.000000000 -0800 -+++ psutil-release-5.8.0/psutil/tests/test_misc.py 2021-01-10 15:38:31.104890945 -0800 -@@ -355,7 +355,7 @@ - - def test_setup_script(self): - setup_py = os.path.join(ROOT_DIR, 'setup.py') -- if CI_TESTING and not os.path.exists(setup_py): -+ if not os.path.exists(setup_py): - return self.skipTest("can't find setup.py") - module = import_module_by_path(setup_py) - self.assertRaises(SystemExit, module.setup) -diff --color -Nur psutil-release-5.8.0.orig/psutil/tests/test_system.py psutil-release-5.8.0/psutil/tests/test_system.py ---- psutil-release-5.8.0.orig/psutil/tests/test_system.py 2020-12-18 16:45:00.000000000 -0800 -+++ psutil-release-5.8.0/psutil/tests/test_system.py 2021-01-10 15:38:31.105890946 -0800 -@@ -198,7 +198,7 @@ - self.assertGreater(bt, 0) - self.assertLess(bt, time.time()) - -- @unittest.skipIf(CI_TESTING and not psutil.users(), "unreliable on CI") -+ @unittest.skipIf(not psutil.users(), "unreliable on CI") - def test_users(self): - users = psutil.users() - self.assertNotEqual(users, []) -@@ -510,7 +510,7 @@ - if not AIX and name in ('ctx_switches', 'interrupts'): - self.assertGreater(value, 0) - -- @unittest.skipIf(not HAS_CPU_FREQ, "not suported") -+ @unittest.skip("Unreliable in mock") - def test_cpu_freq(self): - def check_ls(ls): - for nt in ls: -@@ -579,6 +579,7 @@ - def test_disk_usage_bytes(self): - psutil.disk_usage(b'.') - -+ @unittest.skip("unreliable on CI") - def test_disk_partitions(self): - def check_ntuple(nt): - self.assertIsInstance(nt.device, str) -@@ -828,7 +829,7 @@ - - class TestSensorsAPIs(PsutilTestCase): - -- @unittest.skipIf(not HAS_SENSORS_TEMPERATURES, "not supported") -+ @unittest.skip("Unreliable in mock") - def test_sensors_temperatures(self): - temps = psutil.sensors_temperatures() - for name, entries in temps.items(): -diff --color -Nur psutil-release-5.8.0.orig/psutil/tests/test_testutils.py psutil-release-5.8.0/psutil/tests/test_testutils.py ---- psutil-release-5.8.0.orig/psutil/tests/test_testutils.py 2020-12-18 16:45:00.000000000 -0800 -+++ psutil-release-5.8.0/psutil/tests/test_testutils.py 2021-01-10 15:48:14.240695423 -0800 -@@ -364,7 +364,7 @@ - self.assertRaises(ValueError, self.execute, lambda: 0, retries=-1) - - @retry_on_failure() -- @unittest.skipIf(CI_TESTING, "skipped on CI") -+ @unittest.skip("Unreliable in mock") - def test_leak_mem(self): - ls = [] - diff --git a/test_bundled.fmf b/test_bundled.fmf deleted file mode 100644 index 998894f..0000000 --- a/test_bundled.fmf +++ /dev/null @@ -1,10 +0,0 @@ -framework: shell -require: -- make -- gcc -- procps-ng -- python3-psutil -- python3-psutil-tests -- python3-devel -- python3-setuptools -test: python3 -m psutil.tests