From c4bcf65ccbd6551b87f855ac691aa59b804cc8c5 Mon Sep 17 00:00:00 2001 From: Paul Lettich Date: Fri, 23 Jul 2021 16:14:43 +0200 Subject: [PATCH 1/2] Add GitHub workflow file Just a simple syntax test with currently used perl versions. --- .github/workflows/perl-test.yml | 34 +++++++++++++++++++++++++++++++++ cpanfile | 7 +++++++ 2 files changed, 41 insertions(+) create mode 100644 .github/workflows/perl-test.yml create mode 100644 cpanfile diff --git a/.github/workflows/perl-test.yml b/.github/workflows/perl-test.yml new file mode 100644 index 0000000..c26caf6 --- /dev/null +++ b/.github/workflows/perl-test.yml @@ -0,0 +1,34 @@ + +name: Perl Tests + +on: + push: + pull_request: + branches: + - 'master' + - 'branch-*' + +jobs: + perl_tester: + runs-on: ubuntu-latest + name: "perl v${{ matrix.perl-version }}" + + strategy: + fail-fast: false + matrix: + perl-version: + - "5.16.3" # CentOS 7 + - "5.26.1" # Ubuntu 18.04 + - "5.30" # Ubuntu 20.04 + + container: + image: perldocker/perl-tester:${{ matrix.perl-version }} + + steps: + - uses: actions/checkout@v2 + - name: uses install-with-cpanm + uses: perl-actions/install-with-cpanm@v1 + with: + cpanfile: "cpanfile" + sudo: false + - run: perl -Mstrict -Mdiagnostics -cw privacyidea_radius.pm diff --git a/cpanfile b/cpanfile new file mode 100644 index 0000000..f65eccd --- /dev/null +++ b/cpanfile @@ -0,0 +1,7 @@ +requires 'LWP'; +requires 'Config::IniFiles'; +requires 'Data::Dump'; +requires 'Try::Tiny'; +requires 'JSON'; +requires 'Time::HiRes'; +requires 'URI::Encode'; From e3e041781fe71faa650dd4c210f351503eff0a05 Mon Sep 17 00:00:00 2001 From: Paul Lettich Date: Fri, 23 Jul 2021 16:19:51 +0200 Subject: [PATCH 2/2] Fix failing perl versions --- .github/workflows/perl-test.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/perl-test.yml b/.github/workflows/perl-test.yml index c26caf6..4a55007 100644 --- a/.github/workflows/perl-test.yml +++ b/.github/workflows/perl-test.yml @@ -17,8 +17,8 @@ jobs: fail-fast: false matrix: perl-version: - - "5.16.3" # CentOS 7 - - "5.26.1" # Ubuntu 18.04 + - "5.16" # CentOS 7 + - "5.26" # Ubuntu 18.04 - "5.30" # Ubuntu 20.04 container: