Repository: AdaCore/e3-core (language: python)

Issue:
Replace AppVeyor by GitHub Actions
It will be easier for us to maintain only one CI pipeline. We were unable first to use GitHub Actions for Windows because of a limitation in rlimit. That one has been fixed and there were only some errors in the testsuite to fix. I've verified that we are able to get a clean report with small adjustments and at the same time I'm changing the Python version for the windows tests from Python 3.7 to Python 3.9 & 3.10 (similar to what we have on Linux).


Discussion / hints:

Fix patch:
diff --git a/README.md b/README.md
index 7303099c..3c9988d1 100644
--- a/README.md
+++ b/README.md
@@ -1,11 +1,12 @@
 The `e3` Project
 ================
 
-[![CII Best Practices](https://bestpractices.coreinfrastructure.org/projects/979/badge)](https://bestpractices.coreinfrastructure.org/projects/979)
+[![Build Status](https://github.com/AdaCore/e3-core/workflows/build/badge.svg)](https://github.com/AdaCore/e3-core/actions?query=branch%3Amaster)
 [![Checked with mypy](http://www.mypy-lang.org/static/mypy_badge.svg)](http://mypy-lang.org/)
 [![Documentation Status](https://readthedocs.org/projects/e3-core/badge/?version=latest)](http://e3-core.readthedocs.io/en/latest/?badge=latest)
 [![codecov](https://codecov.io/gh/AdaCore/e3-core/branch/master/graph/badge.svg)](https://codecov.io/gh/AdaCore/e3-core)
 [![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)
+[![CII Best Practices](https://bestpractices.coreinfrastructure.org/projects/979/badge)](https://bestpractices.coreinfrastructure.org/projects/979)
 
 This present project (`e3`) is a Python framework to ease the development
 of portable automated build systems (compilation, dependencies management,
@@ -14,15 +15,6 @@ binary code packaging, and automated testing).
 The `e3` framework is split across multiple Python packages named `e3-<name>`
 and sharing the same namespace: `e3`.
 
-Code status
-===========
-
-Platform | Status
----------|-------
-Linux    | [![Build Status](https://github.com/AdaCore/e3-core/workflows/build/badge.svg)](https://github.com/AdaCore/e3-core/actions?query=branch%3Amaster)
-Windows  | [![Build status](https://ci.appveyor.com/api/projects/status/c8lgr7t0pmg1q89f/branch/master?svg=true)](https://ci.appveyor.com/project/github-integration-adacore/e3-core/branch/master)
-
-
 `e3-core` content
 =================
 
diff --git a/tox.ini b/tox.ini
index 0ed43433..b977de05 100644
--- a/tox.ini
+++ b/tox.ini
@@ -17,7 +17,7 @@ deps =
      cov: coverage
      codecov: codecov
 
-passenv = APPVEYOR* CI GITHUB_* CODECOV_*
+passenv = CI GITHUB_* CODECOV_*
 extras = config
 
 # Run testsuite with coverage when '-cov' is in the env name


Test patch:
diff --git a/tests/tests_e3/os/process/main_test.py b/tests/tests_e3/os/process/main_test.py
index 8c2c8bbd..7e4b4fe7 100644
--- a/tests/tests_e3/os/process/main_test.py
+++ b/tests/tests_e3/os/process/main_test.py
@@ -292,10 +292,7 @@ def test_interrupt():
 
 @pytest.mark.skipif(psutil is None, reason="require psutil")
 def test_kill_process_tree():
-    is_appveyor_test = bool(os.environ.get("APPVEYOR"))
     wait_timeout = 3
-    if is_appveyor_test:
-        wait_timeout *= 3
     p1 = e3.os.process.Run(
         [sys.executable, "-c", "import time; time.sleep(10); import sys; sys.exit(2)"],
         bg=True,
diff --git a/tests/tests_e3/os/windows/fs/main_test.py b/tests/tests_e3/os/windows/fs/main_test.py
index 74cb5002..e3b29628 100644
--- a/tests/tests_e3/os/windows/fs/main_test.py
+++ b/tests/tests_e3/os/windows/fs/main_test.py
@@ -19,12 +19,10 @@
         FileAttribute,
     )
 
-is_appveyor_test = os.environ.get("APPVEYOR") == "True"
-
 
 @pytest.mark.skipif(
-    sys.platform != "win32" or is_appveyor_test,
-    reason="windows specific test (not working on appveyor)",
+    sys.platform != "win32",
+    reason="windows specific test",
 )
 def test_read_attributes():
     work_dir = os.getcwd()
@@ -35,9 +33,6 @@ def test_read_attributes():
     assert "test_read_attr_file.txt" in str(ntfile)
 
     ntfile.read_attributes()
-    # On appveyor calling as_datetime fails because
-    # ntfile.basic_info.change_time is equal to 0. Ignore this until
-    # we have a real reproducer
     assert datetime.now() - ntfile.basic_info.change_time.as_datetime < timedelta(
         seconds=10
     )