mirror of https://github.com/OpenVidu/openvidu.git
119 lines
5.3 KiB
YAML
119 lines
5.3 KiB
YAML
name: OpenVidu CE Tests
|
|
on:
|
|
push:
|
|
branches:
|
|
- master
|
|
paths-ignore:
|
|
- ".github/workflows/openvidu-components-angular-E2E.yml"
|
|
- "openvidu-components-angular/**"
|
|
- "openvidu-server/docker/**"
|
|
- "openvidu-server/deployments/**"
|
|
pull_request:
|
|
branches:
|
|
- master
|
|
workflow_dispatch:
|
|
inputs:
|
|
TEST_IMAGE:
|
|
description: "Docker image where to run the tests"
|
|
required: true
|
|
default: "openvidu/openvidu-test-e2e:22.04"
|
|
KURENTO_MEDIA_SERVER_IMAGE:
|
|
description: "Docker image of kurento-media-server"
|
|
required: true
|
|
default: "kurento/kurento-media-server:6.18.0"
|
|
MEDIASOUP_CONTROLLER_VERSION:
|
|
description: "Tag of image openvidu/mediasoup-controller"
|
|
required: true
|
|
default: "master"
|
|
KURENTO_JAVA_COMMIT:
|
|
description: 'Commit to use in kurento-java dependencies. If "default" the release version declared in property "version.kurento" of openvidu-parent/pom.xml will be used'
|
|
required: true
|
|
default: "default"
|
|
DOCKER_RECORDING_VERSION:
|
|
description: "Force version of openvidu/openvidu-recording container"
|
|
required: true
|
|
default: "default"
|
|
CHROME_VERSION:
|
|
description: "Version of Chrome to use. Must be a valid image tag from https://hub.docker.com/r/selenium/standalone-chrome/tags"
|
|
required: true
|
|
default: latest
|
|
FIREFOX_VERSION:
|
|
description: "Version of Firefox to use. Must be a valid image tag from https://hub.docker.com/r/selenium/standalone-firefox/tags"
|
|
required: true
|
|
default: latest
|
|
# OPERA_VERSION:
|
|
# description: 'Version of Opera to use. Must be a valid image tag from https://hub.docker.com/r/selenium/standalone-opera/tags'
|
|
# required: true
|
|
# default: latest
|
|
EDGE_VERSION:
|
|
description: "Version of Edge to use. Must be a valid image tag from https://hub.docker.com/r/selenium/standalone-opera/tags"
|
|
required: true
|
|
default: latest
|
|
jobs:
|
|
main:
|
|
runs-on: ubuntu-latest
|
|
container:
|
|
image: ${{ github.event.inputs.TEST_IMAGE }}
|
|
volumes:
|
|
- /var/run/docker.sock:/var/run/docker.sock
|
|
- /opt/openvidu:/opt/openvidu
|
|
env:
|
|
TEST_IMAGE: ${{ github.event.inputs.TEST_IMAGE }}
|
|
KURENTO_SNAPSHOTS_URL: ${{ secrets.KURENTO_SNAPSHOTS_URL }}
|
|
KURENTO_MEDIA_SERVER_IMAGE: ${{ github.event.inputs.KURENTO_MEDIA_SERVER_IMAGE || 'kurento/kurento-media-server:6.18.0' }}
|
|
MEDIASOUP_CONTROLLER_VERSION: ${{ github.event.inputs.MEDIASOUP_CONTROLLER_VERSION || 'master' }}
|
|
KURENTO_JAVA_COMMIT: ${{ github.event.inputs.KURENTO_JAVA_COMMIT || 'default' }}
|
|
DOCKER_RECORDING_VERSION: ${{ github.event.inputs.DOCKER_RECORDING_VERSION || 'default' }}
|
|
CHROME_VERSION: ${{ github.event.inputs.CHROME_VERSION || 'latest' }}
|
|
FIREFOX_VERSION: ${{ github.event.inputs.FIREFOX_VERSION || 'latest' }}
|
|
OPERA_VERSION: ${{ github.event.inputs.OPERA_VERSION || 'latest' }}
|
|
EDGE_VERSION: ${{ github.event.inputs.EDGE_VERSION || 'latest' }}
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
- name: Download commons.sh script
|
|
run: curl -s https://raw.githubusercontent.com/OpenVidu/openvidu/master/ci-scripts/commons.sh -o /opt/commons.sh && chmod u+x /opt/commons.sh
|
|
- name: Clean environment
|
|
run: /opt/commons.sh --clean-environment
|
|
- name: Prepare test environment
|
|
run: |
|
|
TEST_IMAGE_WITHOUT_TAG=$(sed -r "s|^(.+):.+$|\1|g" <<<${TEST_IMAGE})
|
|
/opt/commons.sh --prepare-test-environment "${TEST_IMAGE_WITHOUT_TAG}"
|
|
- name: Setting up Kurento Snapshots
|
|
run: /opt/commons.sh --prepare-kurento-snapshot
|
|
- name: Build openvidu-browser
|
|
run: /opt/commons.sh --build-openvidu-browser
|
|
- name: Build openvidu-node-client
|
|
run: /opt/commons.sh --build-openvidu-node-client
|
|
- name: Build openvidu-java-client
|
|
run: /opt/commons.sh --build-openvidu-java-client
|
|
- name: Build openvidu-parent
|
|
run: /opt/commons.sh --build-openvidu-parent
|
|
- name: Build openvidu-testapp
|
|
run: /opt/commons.sh --build-openvidu-testapp
|
|
- name: Build openvidu-server dashboard
|
|
run: /opt/commons.sh --build-openvidu-server-dashboard
|
|
- name: Build openvidu-server
|
|
run: /opt/commons.sh --build-openvidu-server
|
|
- name: openvidu-server unit tests
|
|
run: ci-scripts/openvidu-e2e-tests.sh --openvidu-server-unit-tests
|
|
- name: openvidu-server integration tests
|
|
run: ci-scripts/openvidu-e2e-tests.sh --openvidu-server-integration-tests
|
|
- name: Environment launch Kurento
|
|
run: ci-scripts/openvidu-e2e-tests.sh --environment-launch-kurento
|
|
- name: Serve openvidu-testapp
|
|
run: /opt/commons.sh --serve-openvidu-testapp
|
|
- name: OpenVidu E2E Tests Kurento
|
|
run: ci-scripts/openvidu-e2e-tests.sh --openvidu-e2e-tests-kurento
|
|
- name: Test reports
|
|
uses: mikepenz/action-junit-report@v3
|
|
if: always() # always run even if the previous step fails
|
|
with:
|
|
report_paths: "**/target/surefire-reports/TEST-*.xml"
|
|
- name: Upload logs
|
|
uses: actions/upload-artifact@v3
|
|
if: always() # always run even if the previous step fails
|
|
with:
|
|
name: Logs
|
|
path: |
|
|
/opt/openvidu/*.log
|