Skip to content

Merge pull request #24339 from ramonlsouza/issue-24223 #1084

Merge pull request #24339 from ramonlsouza/issue-24223

Merge pull request #24339 from ramonlsouza/issue-24223 #1084

name: "Automated tests"
on:
push:
branches:
- "develop"
- "v2.[5-9].x-release"
- "v[3-9].*.x-release"
paths-ignore:
- "docs/**"
- "**/*.md"
- "bigbluebutton-html5/public/locales/*.json"
pull_request:
types: [opened, synchronize, reopened]
paths-ignore:
- "docs/**"
- "**/*.md"
- "bigbluebutton-html5/public/locales/*.json"
permissions:
contents: read
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
build-package:
runs-on: ubuntu-22.04
strategy:
fail-fast: false
matrix:
package:
[
bbb-apps-akka,
bbb-config,
bbb-export-annotations,
bbb-learning-dashboard,
bbb-playback-record,
bbb-graphql-server,
bbb-etherpad,
bbb-web,
bbb-fsesl-akka,
bbb-html5,
bbb-freeswitch,
bbb-webrtc,
others,
]
include:
- package: bbb-apps-akka
cache-files-list: akka-bbb-apps bbb-common-message
- package: bbb-config
cache-files-list: bigbluebutton-config
- package: bbb-export-annotations
cache-files-list: bbb-export-annotations
- package: bbb-learning-dashboard
cache-files-list: bbb-learning-dashboard
- package: bbb-playback-record
build-list: bbb-playback bbb-playback-notes bbb-playback-podcast bbb-playback-presentation bbb-playback-screenshare bbb-playback-video bbb-record-core
cache-files-list: bbb-playback.placeholder.sh bbb-presentation-video.placeholder.sh record-and-playback
- package: bbb-graphql-server
build-name: bbb-graphql-server
build-list: bbb-graphql-server bbb-graphql-middleware bbb-graphql-actions
cache-files-list: bbb-graphql-server bbb-graphql-middleware bbb-graphql-actions
- package: bbb-etherpad
cache-files-list: bbb-etherpad.placeholder.sh
cache-urls-list: https://api.github.com/repos/mconf/ep_pad_ttl/commits https://api.github.com/repos/alangecker/bbb-etherpad-plugin/commits https://api.github.com/repos/mconf/ep_redis_publisher/commits https://api.github.com/repos/alangecker/bbb-etherpad-skin/commits
- package: bbb-web
cache-files-list: bigbluebutton-web bbb-common-message bbb-common-web
- package: bbb-fsesl-akka
cache-files-list: akka-bbb-fsesl bbb-common-message
- package: bbb-html5
build-list: bbb-html5
cache-files-list: bigbluebutton-html5
- package: bbb-freeswitch
build-list: bbb-freeswitch-core bbb-freeswitch-sounds
cache-files-list: freeswitch.placeholder.sh
cache-urls-list: https://ubuntu.bigbluebutton.org/sounds.tar.gz
- package: bbb-webrtc
build-list: bbb-webrtc-sfu bbb-webrtc-recorder
cache-files-list: bbb-webrtc-sfu.placeholder.sh bbb-webrtc-recorder.placeholder.sh
- package: others
build-list: bbb-mkclean bbb-pads bbb-libreoffice-docker bbb-transcription-controller bigbluebutton bbb-livekit
cache-files-list: bbb-pads.placeholder.sh bbb-libreoffice bbb-transcription-controller.placeholder.sh
steps:
- name: Checkout PR's source merged into its target branch
if: github.event_name == 'pull_request'
uses: actions/checkout@v4
with:
ref: refs/pull/${{ github.event.number }}/merge
- name: Checkout commit/branch
if: github.event_name != 'pull_request'
uses: actions/checkout@v4
with:
ref: ${{ github.ref }}
- name: Set cache-key vars
run: |
BUILD_DIRS="$(echo '${{ matrix.build-list || matrix.package }}' | sed 's/[^ ]\+/build\/packages-template\/&/g')"
echo "Including build dirs: $BUILD_DIRS"
LIST="${{ matrix.cache-files-list }} $BUILD_DIRS .gitlab-ci.yml build/deb-helper.sh"
TREE_HASHES=$(echo $LIST | tr ' ' '\n' | xargs -I {} git rev-parse HEAD:{} 2>/dev/null)
CACHE_DIGEST=$(printf "%s" "$TREE_HASHES" | (sha256sum 2>/dev/null || shasum -a 256) | awk '{print $1}')
echo "CACHE_KEY_FILES=$CACHE_DIGEST" >> $GITHUB_ENV
echo "CACHE_KEY_URLS=$(echo '${{ matrix.cache-urls-list }}' | xargs -r -n 1 curl -Is | grep -i 'Last-Modified' | md5sum | cut -c1-10)" >> $GITHUB_ENV
cat bigbluebutton-config/bigbluebutton-release >> $GITHUB_ENV
echo "FORCE_GIT_REV=0" >> $GITHUB_ENV #used by setup.sh
echo "FORCE_COMMIT_DATE=0" >> $GITHUB_ENV #used by setup.sh
- name: Handle cache
if: matrix.cache-files-list != ''
id: cache-action
uses: actions/cache@v4
with:
path: artifacts/
key: ${{ runner.os }}-${{ matrix.package }}-${{ env.BIGBLUEBUTTON_RELEASE }}-commits-${{ env.CACHE_KEY_FILES }}-urls-${{ env.CACHE_KEY_URLS }}
- if: ${{ steps.cache-action.outputs.cache-hit != 'true' }}
name: Generate artifacts
shell: bash
run: |
./build/get_external_dependencies.sh
echo "${{ matrix.build-list || matrix.package }}" | xargs -n 1 ./build/setup.sh
- name: Sanitize artifact filenames
shell: bash
run: |
if [ -d "artifacts" ]; then
echo "Sanitizing filenames to remove problematic characters..."
find artifacts -name "*:*" -type f | while read -r file; do
# Replace colons with underscores
newfile=$(echo "$file" | sed 's/:/_/g')
echo "Renaming: $file -> $newfile"
mv "$file" "$newfile"
done
echo "Final artifacts contents:"
ls -la artifacts/
fi
- name: Archive packages
uses: actions/upload-artifact@v4
with:
name: artifacts_${{ matrix.package }}
path: artifacts/
bbb-libreoffice-image:
runs-on: ubuntu-22.04
steps:
- name: Checkout PR's source merged into its target branch
if: github.event_name == 'pull_request'
uses: actions/checkout@v4
with:
ref: refs/pull/${{ github.event.number }}/merge
- name: Checkout commit/branch
if: github.event_name != 'pull_request'
uses: actions/checkout@v4
with:
ref: ${{ github.ref }}
- name: LIBREOFFICE CACHE - Set cache-key vars
run: |
echo "BBB_LIBREOFFICE_IMAGE_NAME=$(head -n 1 bbb-libreoffice/docker/Dockerfile | cut -d ' ' -f 2)" >> $GITHUB_ENV
- name: LIBREOFFICE CACHE - Restore docker image from cache
id: libreoffice-cache
uses: actions/cache@v4
with:
path: bbb-libreoffice.tar
key: ${{ env.BBB_LIBREOFFICE_IMAGE_NAME }}
- name: LIBREOFFICE CACHE - Pull and save docker image (first time / cache miss)
if: steps.libreoffice-cache.outputs.cache-hit != 'true'
run: |
docker pull docker.io/${{ env.BBB_LIBREOFFICE_IMAGE_NAME }}
docker save docker.io/${{ env.BBB_LIBREOFFICE_IMAGE_NAME }} -o bbb-libreoffice.tar
unify-artifacts:
needs: build-package
runs-on: ubuntu-22.04
steps:
- name: Create all-artifacts directory
run: mkdir -p all-artifacts
- name: Download artifacts_bbb-apps-akka
uses: actions/download-artifact@v4
with:
name: artifacts_bbb-apps-akka
path: all-artifacts
- name: Download artifacts_bbb-config
uses: actions/download-artifact@v4
with:
name: artifacts_bbb-config
path: all-artifacts
- name: Download artifacts_bbb-export-annotations
uses: actions/download-artifact@v4
with:
name: artifacts_bbb-export-annotations
path: all-artifacts
- name: Download artifacts_bbb-learning-dashboard
uses: actions/download-artifact@v4
with:
name: artifacts_bbb-learning-dashboard
path: all-artifacts
- name: Download artifacts_bbb-playback-record
uses: actions/download-artifact@v4
with:
name: artifacts_bbb-playback-record
path: all-artifacts
- name: Download artifacts_bbb-graphql-server
uses: actions/download-artifact@v4
with:
name: artifacts_bbb-graphql-server
path: all-artifacts
- name: Download artifacts_bbb-etherpad
uses: actions/download-artifact@v4
with:
name: artifacts_bbb-etherpad
path: all-artifacts
- name: Download artifacts_bbb-freeswitch
uses: actions/download-artifact@v4
with:
name: artifacts_bbb-freeswitch
path: all-artifacts
- name: Download artifacts_bbb-webrtc
uses: actions/download-artifact@v4
with:
name: artifacts_bbb-webrtc
path: all-artifacts
- name: Download artifacts_bbb-web
uses: actions/download-artifact@v4
with:
name: artifacts_bbb-web
path: all-artifacts
- name: Download artifacts_bbb-fsesl-akka
uses: actions/download-artifact@v4
with:
name: artifacts_bbb-fsesl-akka
path: all-artifacts
- name: Download artifacts_bbb-html5
uses: actions/download-artifact@v4
with:
name: artifacts_bbb-html5
path: all-artifacts
- name: Download artifacts_others
uses: actions/download-artifact@v4
with:
name: artifacts_others
path: all-artifacts
- name: List final artifacts
run: |
echo "Final contents of all-artifacts:"
ls -la all-artifacts/
- name: Upload unified all-artifacts directory
uses: actions/upload-artifact@v4
with:
name: all-bbb-artifacts
path: all-artifacts/
- name: Remove individual artifacts
uses: geekyeggo/delete-artifact@v5
with:
name: |
artifacts_bbb-apps-akka
artifacts_bbb-config
artifacts_bbb-export-annotations
artifacts_bbb-learning-dashboard
artifacts_bbb-playback-record
artifacts_bbb-graphql-server
artifacts_bbb-etherpad
artifacts_bbb-freeswitch
artifacts_bbb-webrtc
artifacts_bbb-web
artifacts_bbb-fsesl-akka
artifacts_bbb-html5
artifacts_others
failOnError: false
install-and-run-bbb-tests:
needs:
- unify-artifacts
- bbb-libreoffice-image
runs-on: ubuntu-22.04
strategy:
fail-fast: false
matrix:
shard: [1, 2, 3, 4, 5, 6, 7, 8]
env:
shard: ${{ matrix.shard }}/8
MATRIX_SHARD_UNDERSCORED: ${{ matrix.shard }}_8
steps:
- name: Checkout PR's source merged into its target branch
if: github.event_name == 'pull_request'
uses: actions/checkout@v4
with:
ref: refs/pull/${{ github.event.number }}/merge
- name: Checkout commit/branch
if: github.event_name != 'pull_request'
uses: actions/checkout@v4
with:
ref: ${{ github.ref }}
- name: Install BBB
timeout-minutes: 60
uses: ./.github/actions/install-bbb
- uses: actions/setup-node@v4
name: PLAYRIGHT CACHE - Restore Playright node modules from cache
with:
cache: "npm"
cache-dependency-path: bigbluebutton-tests/playwright/package-lock.json
- name: PLAYRIGHT CACHE - Restore Playright binaries from cache
id: cache
uses: actions/cache@v4
with:
path: /home/runner/.cache/ms-playwright/
key: ${{ runner.os }}-playwright-bins-${{ hashFiles('bigbluebutton-tests/playwright/package-lock.json') }}
- name: Install test dependencies
working-directory: ./bigbluebutton-tests/playwright
timeout-minutes: 25
run: |
npm ci
npx playwright install-deps
npx playwright install
- name: Run tests
working-directory: ./bigbluebutton-tests/playwright
timeout-minutes: 25
env:
NODE_EXTRA_CA_CERTS: /usr/local/share/ca-certificates/bbb-dev/bbb-dev-ca.crt
ACTIONS_RUNNER_DEBUG: true
BBB_URL: https://bbb-ci.test/bigbluebutton/
BBB_SECRET: bbbci
run: npm run test-chromium-ci -- --shard=${{ env.shard }}
- name: Run Firefox tests
working-directory: ./bigbluebutton-tests/playwright
if: |
contains(join(github.event.pull_request.labels.*.name, ' '), 'test Firefox') ||
contains(join(github.event.pull_request.labels.*.name, ' '), 'Test Firefox')
env:
NODE_EXTRA_CA_CERTS: /usr/local/share/ca-certificates/bbb-dev/bbb-dev-ca.crt
ACTIONS_RUNNER_DEBUG: true
BBB_URL: https://bbb-ci.test/bigbluebutton/
BBB_SECRET: bbbci
# patch playwright's firefox so that it uses the system's root certificate authority
run: |
find $HOME/.cache/ms-playwright -name libnssckbi.so -exec rm {} \; -exec ln -s /usr/lib/x86_64-linux-gnu/pkcs11/p11-kit-trust.so {} \;
npm run test-firefox-ci -- --shard=${{ env.shard }}
- if: always()
name: Upload blob report to GitHub Actions Artifacts
uses: actions/upload-artifact@v4
with:
name: blob-report-${{ matrix.shard }}
path: bigbluebutton-tests/playwright/blob-report
if-no-files-found: ignore
- if: always()
name: Generate the shard HTML report from blob report
shell: bash
working-directory: ./bigbluebutton-tests/playwright
run: |
if [ -d "./blob-report" ]; then
npx playwright merge-reports --reporter html ./blob-report
else
echo "blob-report directory not found, skipping HTML report generation"
fi
- if: always()
name: Upload shard HTML report to GitHub Actions Artifacts
uses: actions/upload-artifact@v4
with:
name: test-report_shard-${{ matrix.shard }}
path: bigbluebutton-tests/playwright/playwright-report
- if: always()
name: Upload logs folder
uses: actions/upload-artifact@v4
with:
name: browser-logs-${{ matrix.shard }}
path: bigbluebutton-tests/playwright/logs
- if: failure()
name: Prepare artifacts
uses: ./.github/actions/prepare-artifacts
- if: failure()
name: Upload bbb-configs artifact
uses: actions/upload-artifact@v4
with:
name: bbb-configs-${{ env.MATRIX_SHARD_UNDERSCORED }}
path: configs
- if: failure()
name: Upload bbb-logs artifact
uses: actions/upload-artifact@v4
with:
name: bbb-logs-${{ env.MATRIX_SHARD_UNDERSCORED }}
path: ./bbb-logs.tar.gz
- name: APT CACHE - Check for changes using packages hash
if: success() && matrix.shard == 1 && github.event_name != 'pull_request'
id: apt-manifest
shell: bash
run: |
sudo chown -R "$USER:$USER" /var/cache/apt/archives || true
sudo chmod 755 /var/cache/apt/archives /var/cache/apt/archives/partial 2>/dev/null || true
hash=$(find /var/cache/apt/archives -type f -name '*.deb' \
| sort \
| sha256sum \
| cut -d' ' -f1)
echo "hash=$hash" >> $GITHUB_OUTPUT
- name: APT CACHE - Upload new packages (if changed)
if: success() && matrix.shard == 1 && github.event_name != 'pull_request'
uses: actions/cache/save@v4
with:
path: /var/cache/apt/archives
key: ${{ runner.os }}-apt-${{ hashFiles('bigbluebutton-config/bigbluebutton-release') }}-${{ steps.apt-manifest.outputs.hash }}
install-and-run-plugin-tests:
needs:
- unify-artifacts
- bbb-libreoffice-image
runs-on: ubuntu-22.04
strategy:
fail-fast: false
env:
SAMPLES_WITH_TESTS: "sample-action-button-dropdown-plugin sample-actions-bar-plugin sample-audio-settings-dropdown-plugin sample-camera-settings-dropdown-plugin sample-custom-subscription-hook sample-data-channel-plugin"
steps:
- name: Checkout PR's source merged into its target branch
if: github.event_name == 'pull_request'
uses: actions/checkout@v4
with:
ref: refs/pull/${{ github.event.number }}/merge
- name: Checkout commit/branch
if: github.event_name != 'pull_request'
uses: actions/checkout@v4
with:
ref: ${{ github.ref }}
- name: Install BBB
timeout-minutes: 60
uses: ./.github/actions/install-bbb
- name: Extract download URL of the SDK version information from bigbluebutton-html5/package.json
working-directory: ./bigbluebutton-html5
run: |
SDK_DEP=$(jq -r '.dependencies["bigbluebutton-html-plugin-sdk"]' package.json)
if echo "$SDK_DEP" | grep -q "codeload.github.com"; then
echo "SDK_URL=$SDK_DEP" >> $GITHUB_ENV
else
SDK_VERSION=$(jq -r '.packages["node_modules/bigbluebutton-html-plugin-sdk"]["version"]' package-lock.json)
echo "SDK_URL=https://github.com/bigbluebutton/bigbluebutton-html-plugin-sdk/archive/refs/tags/v${SDK_VERSION}.tar.gz" >> $GITHUB_ENV
fi
- name: Plugins SDK - Download bigbluebutton-html-plugin-sdk.tar.gz
working-directory: bigbluebutton-tests
run: |
wget -O bigbluebutton-html-plugin-sdk.tar.gz $SDK_URL
mkdir -p bigbluebutton-html-plugin-sdk
tar -xzf bigbluebutton-html-plugin-sdk.tar.gz -C bigbluebutton-html-plugin-sdk --strip-components=1
- name: PLAYRIGHT CACHE (Plugins SDK) - Restore Playright node modules from cache
uses: actions/setup-node@v4
with:
cache: "npm"
cache-dependency-path: |
bigbluebutton-tests/bigbluebutton-html-plugin-sdk/package-lock.json
bigbluebutton-tests/bigbluebutton-html-plugin-sdk/samples/**/package-lock.json
- name: PLAYRIGHT CACHE - Restore Playright binaries from cache
id: cache
uses: actions/cache@v4
with:
path: /home/runner/.cache/ms-playwright/
key: ${{ runner.os }}-playwright-bins-${{ hashFiles('bigbluebutton-tests/bigbluebutton-html-plugin-sdk/package-lock.json') }}
- name: Plugins SDK - Install node dependencies
working-directory: ./bigbluebutton-tests/bigbluebutton-html-plugin-sdk
run: |
echo "Installing plugins SDK dependencies"
npm ci
- name: Install sample plugin dependencies
working-directory: ./bigbluebutton-tests/bigbluebutton-html-plugin-sdk
run: |
echo "Installing plugin samples dependencies"
for sample in $SAMPLES_WITH_TESTS; do
if [ -d "./samples/$sample" ]; then
echo "Installing dependencies for sample: $sample"
cd "./samples/$sample"
npm ci
cd - > /dev/null
else
echo "Sample not found: $sample"
fi
done
- name: Build plugins SDK and publish to samples
working-directory: ./bigbluebutton-tests/bigbluebutton-html-plugin-sdk
run: |
npm ci
npm run build
./scripts/publish-to-samples.sh
- name: Build sample plugins (that contain tests) and copy built files to the plugin assets directory
working-directory: ./bigbluebutton-tests/bigbluebutton-html-plugin-sdk
run: |
echo "Building all samples inside the 'samples' directory that contain tests"
for sample in $SAMPLES_WITH_TESTS; do
if [ -d "./samples/$sample" ]; then
echo "Building sample: $sample"
cd "./samples/$sample"
npm run build-bundle
sudo mkdir -p /var/www/bigbluebutton-default/assets/plugins/$sample
sudo cp -r dist /var/www/bigbluebutton-default/assets/plugins/$sample/
cd - > /dev/null
else
echo "Sample not found: $sample"
fi
done
- name: Install test dependencies
working-directory: ./bigbluebutton-tests/bigbluebutton-html-plugin-sdk
timeout-minutes: 25
run: |
npm ci
npx playwright install-deps
npx playwright install
- name: Prepare flaky test exclusions
working-directory: ./bigbluebutton-tests/bigbluebutton-html-plugin-sdk
run: |
# Read flaky tests from core repo and build a grep-invert parameter
FLAKY_TESTS_FILE="sdk-flaky-tests.txt"
FLAKY_TESTS_LINES=""
if [ -f "$FLAKY_TESTS_FILE" ]; then
echo "Reading flaky tests from $FLAKY_TESTS_FILE"
# Process the file:
# - remove CRLF if present (Windows line endings)
# - ignore comments (#...) and empty lines
# - escape regex metacharacters to avoid breaking grep
# - replace " › " with ".*" to allow flexible matching
# - join all patterns into a single alternation regex separated by '|'
FLAKY_TESTS_LINES="$(
sed 's/\r$//' "$FLAKY_TESTS_FILE" \
| grep -Ev '^[[:space:]]*(#|$)' \
| sed -E 's/[][(){}.^$*+?|\]/\\&/g' \
| sed 's/ › /.*/g' \
| paste -sd'|' -
)"
# If we have patterns, print them; otherwise, say none found
if [ -n "$FLAKY_TESTS_LINES" ]; then
echo "Will skip flaky tests: $FLAKY_TESTS_LINES"
else
echo "No flaky tests to skip"
fi
else
# If the file does not exist, just run all tests
echo "Flaky tests file not found, running all tests"
fi
# Export the variable so it can be used in later GitHub Actions steps
echo "SDK_FLAKY_TESTS=$FLAKY_TESTS_LINES" >> "$GITHUB_ENV"
- name: Run tests
working-directory: ./bigbluebutton-tests/bigbluebutton-html-plugin-sdk
timeout-minutes: 25
env:
NODE_EXTRA_CA_CERTS: /usr/local/share/ca-certificates/bbb-dev/bbb-dev-ca.crt
ACTIONS_RUNNER_DEBUG: true
BBB_URL: https://bbb-ci.test/bigbluebutton/
BBB_SECRET: bbbci
run: npm run test-chromium-ci -- --grep-invert "$SDK_FLAKY_TESTS"
- if: always()
name: Upload blob report to GitHub Actions Artifacts
uses: actions/upload-artifact@v4
with:
name: blob-report-plugins
path: bigbluebutton-tests/bigbluebutton-html-plugin-sdk/blob-report
- if: always()
name: Generate the plugins HTML report from blob report
shell: bash
working-directory: ./bigbluebutton-tests/bigbluebutton-html-plugin-sdk
run: |
if [ -d "./blob-report" ]; then
npx playwright merge-reports --reporter html ./blob-report
else
echo "blob-report directory not found, skipping HTML report generation"
fi
- if: always()
name: Upload shard HTML report to GitHub Actions Artifacts
uses: actions/upload-artifact@v4
with:
name: test-report_plugins
path: bigbluebutton-tests/bigbluebutton-html-plugin-sdk/playwright-report
- if: always()
name: Upload logs folder
uses: actions/upload-artifact@v4
with:
name: browser-logs-plugin
path: bigbluebutton-tests/bigbluebutton-html-plugin-sdk/logs
if-no-files-found: ignore
- if: failure()
name: Prepare artifacts
uses: ./.github/actions/prepare-artifacts
- if: failure()
name: Upload bbb-configs artifact
uses: actions/upload-artifact@v4
with:
name: bbb-configs-plugins
path: configs
- if: failure()
name: Upload bbb-logs artifact
uses: actions/upload-artifact@v4
with:
name: bbb-logs-plugins
path: ./bbb-logs.tar.gz
upload-report:
if: always() && !contains(github.event.head_commit.message, 'Merge pull request')
needs:
- install-and-run-bbb-tests
- install-and-run-plugin-tests
runs-on: ubuntu-22.04
env:
hasReportData: ${{ needs.install-and-run-bbb-tests.result == 'success' || needs.install-and-run-bbb-tests.result == 'failure' && needs.install-and-run-plugin-tests.result == 'success' || needs.install-and-run-plugin-tests.result == 'failure' }}
steps:
# temporarily disabled as merged blob reports are not being used
# - name: Merge and upload the blob reports
# if: ${{ env.hasReportData }}
# uses: ./.github/actions/merge-and-upload-blob-reports
# - name: Remove unnecessary artifact
# uses: geekyeggo/delete-artifact@v5
# with:
# name: all-blob-reports
# failOnError: false
- name: Remove unnecessary blob artifacts
uses: geekyeggo/delete-artifact@v5
with:
name: blob-report-*
failOnError: false
- name: Write PR data for auto-comment
if: github.event_name == 'pull_request'
working-directory: ./
run: |
mkdir -p ./pr-comment-data
echo ${{ github.event.number }} > ./pr-comment-data/pr_number
echo ${{ github.run_id }} > ./pr-comment-data/workflow_id
- name: Upload PR data for auto-comment
if: github.event_name == 'pull_request'
uses: actions/upload-artifact@v4
with:
name: pr-comment-data
path: pr-comment-data