Skip to content

fix(CTOR-696) Fix tests #2553

fix(CTOR-696) Fix tests

fix(CTOR-696) Fix tests #2553

Workflow file for this run

name: spell-checker
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
on:
workflow_dispatch:
pull_request:
paths:
- '.github/workflows/spellchecker.yml'
- 'src/**'
- '.github/scripts/pod_spell_check.t'
jobs:
dependency-scan:
uses: centreon/security-tools/.github/workflows/dependency-analysis.yml@main
pod-spell-check:
needs: [dependency-scan]
if: ${{ !contains(github.event.pull_request.labels.*.name, 'do-not-spellcheck') }}
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: dorny/paths-filter@fbd0ab8f3e69293af611ebaee6363fc25e6d187d # v4.0.1
id: filter
with:
base: ${{ github.ref }}
list-files: shell
filters: |
plugins:
- added|modified: 'src/**/*.pm'
- name: Install CPAN Libraries
uses: shogo82148/actions-setup-perl@9f8c263975569ff3b4e510cb1f8813115749e146 # v1.41.0
with:
perl-version: '5.34'
install-modules-with: cpm
install-modules: Test::More Test::Spelling List::MoreUtils
- name: Install librairies
continue-on-error: true
run: |
sudo apt-get update
sudo apt-get install -y hunspell
shell: bash
- name: Run spell check
id: run_check
env:
PLUGINS_FILES: ${{ steps.filter.outputs.plugins_files }}
run: |
set +e
for f in $PLUGINS_FILES; do
echo "perl .github/scripts/pod_spell_check.t $f"
output=$(perl .github/scripts/pod_spell_check.t $f)
done
shell: bash