Skip to content

Commit a25381b

Browse files
author
QuasarStream Team
committed
Fixes #147 and add GitHub workflow
1 parent 1c2167b commit a25381b

File tree

7 files changed

+80
-144
lines changed

7 files changed

+80
-144
lines changed

.appveyor.yml

Lines changed: 0 additions & 50 deletions
This file was deleted.

.github/lock.yml

Lines changed: 0 additions & 35 deletions
This file was deleted.

.github/workflows/blank.yml

Lines changed: 0 additions & 17 deletions
This file was deleted.

.github/workflows/tests.yml

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
name: PHP FFMPEG - VIDEO STREAMING - TESTS
2+
3+
on:
4+
push:
5+
branches: [ "master" ]
6+
pull_request:
7+
branches: [ "master" ]
8+
9+
permissions:
10+
contents: read
11+
12+
jobs:
13+
test:
14+
runs-on: ubuntu-latest
15+
16+
steps:
17+
- uses: actions/checkout@v4
18+
19+
- name: Set up PHP 8.4
20+
uses: shivammathur/setup-php@v2
21+
with:
22+
php-version: 8.4
23+
tools: composer:v2
24+
25+
- name: Validate composer.json and composer.lock
26+
run: composer validate --strict
27+
28+
- name: Cache Composer packages
29+
id: composer-cache
30+
uses: actions/cache@v3
31+
with:
32+
path: vendor
33+
key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }}
34+
restore-keys: |
35+
${{ runner.os }}-php-
36+
37+
- name: Install dependencies
38+
run: composer install --prefer-dist --no-progress
39+
40+
- name: Install FFmpeg
41+
run: |
42+
sudo apt-get update
43+
sudo apt-get install -y ffmpeg
44+
ffmpeg -version
45+
46+
- name: Check PHP version and extensions
47+
run: |
48+
php -v
49+
php -m | grep -i gmp
50+
which ffmpeg
51+
52+
- name: Run PHPUnit tests
53+
run: vendor/bin/phpunit

.travis.yml

Lines changed: 0 additions & 32 deletions
This file was deleted.

composer.json

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
"authors": [
3535
{
3636
"name": "Amin Yazdanpanah",
37-
"email": "contact@aminyazdanpanah.com",
37+
"email": "github@aminyazdanpanah.com",
3838
"homepage": "https://www.aminyazdanpanah.com"
3939
}
4040
],
@@ -63,14 +63,7 @@
6363
},
6464
"require": {
6565
"php": "^7.2 || ^8.0 || ^8.1 || ^8.2 || ^8.3 || ^8.4",
66-
"php-ffmpeg/php-ffmpeg": "^0.15 || 0.16 || 0.17 || 0.18 || 0.19 || ^1.0 || ^1.1 || ^1.2",
67-
"symfony/filesystem": "^4.0 || ^5.0 || ^6.0"
68-
},
69-
"suggest": {
70-
"aminyazdanpanah/php-shaka": "aminyazdanpanah/php-shaka is suggested for using DRM and encryption",
71-
"aws/aws-sdk-php": "Allow sending stream content to AWS services like S3",
72-
"google/cloud-storage": "Allow sending stream content to Google services like Google Storage",
73-
"microsoft/azure-storage-blob": "Allow sending stream content to Google services like Google Storage",
74-
"aminyazdanpanah/handling-file-uploads": "aminyazdanpanah/handling-file-uploads is suggested for uploading and validating a new video."
66+
"php-ffmpeg/php-ffmpeg": "^0.15 || 0.16 || 0.17 || 0.18 || 0.19 || ^1.0 || ^1.1 || ^1.2 || ^1.3",
67+
"symfony/filesystem": "4.0 || ^5.0 || ^6.0 || ^7.0 || ^8.0"
7568
}
7669
}

phpunit.xml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3+
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/8.5/phpunit.xsd"
4+
bootstrap="vendor/autoload.php"
5+
cacheResultFile=".phpunit.cache/test-results"
6+
executionOrder="depends,defects"
7+
forceCoversAnnotation="true"
8+
beStrictAboutCoversAnnotation="true"
9+
beStrictAboutOutputDuringTests="true"
10+
beStrictAboutTodoAnnotatedTests="true"
11+
convertDeprecationsToExceptions="true"
12+
verbose="true">
13+
<testsuites>
14+
<testsuite name="default">
15+
<directory>tests</directory>
16+
</testsuite>
17+
</testsuites>
18+
19+
<filter>
20+
<whitelist processUncoveredFilesFromWhitelist="true">
21+
<directory suffix=".php">src</directory>
22+
</whitelist>
23+
</filter>
24+
</phpunit>

0 commit comments

Comments
 (0)