[Openvpn-devel] GHA: refactor mingw UTs and add missing tls_crypt

Message ID 20230718105233.620193-1-frank@lichtenheld.com
State Accepted
Headers show
Series [Openvpn-devel] GHA: refactor mingw UTs and add missing tls_crypt | expand

Commit Message

Frank Lichtenheld July 18, 2023, 10:52 a.m. UTC
I thought instead about moving this into a loop inside
powershell. But then error handling becomes annoying.
So let's GitHub handle it.

Change-Id: I9831f352c07b5c58a4e2d6a3dd5417842e0887d2
Signed-off-by: Frank Lichtenheld <frank@lichtenheld.com>
---
 .github/workflows/build.yaml | 38 ++++--------------------------------
 1 file changed, 4 insertions(+), 34 deletions(-)

Comments

Arne Schwabe July 18, 2023, 10:59 a.m. UTC | #1
Am 18.07.23 um 12:52 schrieb Frank Lichtenheld:
> I thought instead about moving this into a loop inside
> powershell. But then error handling becomes annoying.
> So let's GitHub handle it.
> 

Acked-By: Arne Schwabe <arne@rfc2549.org>

I personally do not mind the long list of repeated unit tests in the 
file but this way is also fine.

I checked Frank's repository to verify that this actually works.

Arne
Gert Doering July 18, 2023, 1:22 p.m. UTC | #2
Tested in my GHA instance -> does the job, thanks.

(There is lots of individual results in the left column now, but as
long as it's all green, it does not really matter... as long as it's
not burning 10 times the credits now?)

Your patch has been applied to the master branch.

commit 26c663f12815f55c483dbe660e28448dc63221d1
Author: Frank Lichtenheld
Date:   Tue Jul 18 12:52:33 2023 +0200

     GHA: refactor mingw UTs and add missing tls_crypt

     Signed-off-by: Frank Lichtenheld <frank@lichtenheld.com>
     Acked-by: Arne Schwabe <arne@rfc2549.org>
     Message-Id: <20230718105233.620193-1-frank@lichtenheld.com>
     URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg26868.html
     Signed-off-by: Gert Doering <gert@greenie.muc.de>


--
kind regards,

Gert Doering

Patch

diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml
index da2a427c..2ae231ee 100644
--- a/.github/workflows/build.yaml
+++ b/.github/workflows/build.yaml
@@ -85,48 +85,18 @@  jobs:
       fail-fast: false
       matrix:
         arch: [x86, x64]
+        test: [argv, auth_token, buffer, cryptoapi, crypto, misc, ncp, packet_id, pkt, provider, tls_crypt]
 
     runs-on: windows-latest
-    name: "mingw unittests - ${{ matrix.arch }} - OSSL"
+    name: "mingw unittest ${{ matrix.test }} - ${{ matrix.arch }} - OSSL"
     steps:
       - name: Retrieve mingw unittest
         uses: actions/download-artifact@v3
         with:
           name: openvpn-mingw-${{ matrix.arch }}-tests
           path: unittests
-
-      - name: List unittests directory
-        run: "dir unittests"
-
-      - name: Run argv unit test
-        run: ./unittests/test_argv.exe
-
-      - name: Run auth_token unit test
-        run: ./unittests/test_auth_token.exe
-
-      - name: Run buffer unit test
-        run: ./unittests/test_buffer.exe
-
-      - name: Run cryptoapi unit test
-        run: ./unittests/test_cryptoapi.exe
-
-      - name: Run crypto unit test
-        run: ./unittests/test_crypto.exe
-
-      - name: Run misc unit test
-        run: ./unittests/test_misc.exe
-
-      - name: Run ncp unit test
-        run: ./unittests/test_ncp.exe
-
-      - name: Run packet id unit test
-        run: ./unittests/test_packet_id.exe
-
-      - name: Run pkt unit test
-        run: ./unittests/test_pkt.exe
-
-      - name: Run provider unit test
-        run: ./unittests/test_provider.exe
+      - name: Run ${{ matrix.test }} unit test
+        run: ./unittests/test_${{ matrix.test }}.exe
 
   ubuntu:
     strategy: