Skip to content

🎥 Make videos programmatically with React

more tests

Jonny Burger458adea66a91
diff --git a/packages/it-tests/src/rendering/rendering.test.ts b/packages/it-tests/src/rendering/rendering.test.ts
index 67ef67c3da..355333939c 100644
--- a/packages/it-tests/src/rendering/rendering.test.ts
+++ b/packages/it-tests/src/rendering/rendering.test.ts
@@ -382,7 +382,9 @@ test("Should render a still that uses the staticFile() API and should apply prop
fs.unlinkSync(out);
});
-test("Dynamic duration should work", async () => {
+test("Dynamic duration should work and audio separation", async () => {
+ const audio = path.join(process.cwd(), "..", "example", "audio.wav");
+
const randomDuration = Math.round(Math.random() * 18 + 2);
const task = await execa(
"pnpm",
@@ -418,11 +420,28 @@ test("Dynamic duration should work", async () => {
expect(data).toContain("Video: h264");
const expectedDuration = (randomDuration / 30).toFixed(2);
expect(data).toContain(`Duration: 00:00:0${expectedDuration}`);
+ expect(data).toContain(
+ `Stream #0:0[0x1](und): Video: h264 (avc1 / 0x31637661), yuv420p(tv, bt470bg/unknown/unknown, progressive)`
+ );
fs.unlinkSync(outputPath);
+
+ const audioInfo = await RenderInternals.callFf({
+ bin: "ffprobe",
+ args: [audio],
+ indent: false,
+ logLevel: "info",
+ binariesDirectory: null,
+ cancelSignal: undefined,
+ });
+ const audioData = audioInfo.stderr;
+ expect(audioData).toContain(
+ " Stream #0:0: Audio: pcm_s16le ([1][0][0][0] / 0x0001), 48000 Hz, 2 channels, s16"
+ );
+ fs.unlinkSync(audio);
});
-test("Should be able to render if remotion.config.js is not provided", async () => {
+test("Should be able to render if remotion.config.js is not provided, and separate audio", async () => {
const task = await execa(
"node",
[
diff --git a/packages/lambda-php/composer.lock b/packages/lambda-php/composer.lock
index 4a0553964b..6a44bf5fc1 100644
--- a/packages/lambda-php/composer.lock
+++ b/packages/lambda-php/composer.lock
@@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
- "content-hash": "68e83650c908595e6e387888f172c515",
+ "content-hash": "e662629f0a32d655e5f55e16dffdaab1",
"packages": [
{
"name": "aws/aws-crt-php",
@@ -62,16 +62,16 @@
},
{
"name": "aws/aws-sdk-php",
- "version": "3.300.3",
+ "version": "3.300.13",
"source": {
"type": "git",
"url": "https://github.com/aws/aws-sdk-php.git",
- "reference": "a1202d1a82593fc2cdad54d627e54c518a984738"
+ "reference": "b1eb7307d30ebcfa4e156971f658c2d177434db3"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/a1202d1a82593fc2cdad54d627e54c518a984738",
- "reference": "a1202d1a82593fc2cdad54d627e54c518a984738",
+ "url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/b1eb7307d30ebcfa4e156971f658c2d177434db3",
+ "reference": "b1eb7307d30ebcfa4e156971f658c2d177434db3",
"shasum": ""
},
"require": {
@@ -151,9 +151,9 @@
"support": {
"forum": "https://forums.aws.amazon.com/forum.jspa?forumID=80",
"issues": "https://github.com/aws/aws-sdk-php/issues",
- "source": "https://github.com/aws/aws-sdk-php/tree/3.300.3"
+ "source": "https://github.com/aws/aws-sdk-php/tree/3.300.13"
},
- "time": "2024-02-22T19:20:21+00:00"
+ "time": "2024-03-07T19:14:04+00:00"
},
{
"name": "guzzlehttp/guzzle",
@@ -960,16 +960,16 @@
},
{
"name": "nikic/php-parser",
- "version": "v5.0.1",
+ "version": "v5.0.2",
"source": {
"type": "git",
"url": "https://github.com/nikic/PHP-Parser.git",
- "reference": "2218c2252c874a4624ab2f613d86ac32d227bc69"
+ "reference": "139676794dc1e9231bf7bcd123cfc0c99182cb13"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/2218c2252c874a4624ab2f613d86ac32d227bc69",
- "reference": "2218c2252c874a4624ab2f613d86ac32d227bc69",
+ "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/139676794dc1e9231bf7bcd123cfc0c99182cb13",
+ "reference": "139676794dc1e9231bf7bcd123cfc0c99182cb13",
"shasum": ""
},
"require": {
@@ -1012,26 +1012,27 @@
],
"support": {
"issues": "https://github.com/nikic/PHP-Parser/issues",
- "source": "https://github.com/nikic/PHP-Parser/tree/v5.0.1"
+ "source": "https://github.com/nikic/PHP-Parser/tree/v5.0.2"
},
- "time": "2024-02-21T19:24:10+00:00"
+ "time": "2024-03-05T20:51:40+00:00"
},
{
"name": "phar-io/manifest",
- "version": "2.0.3",
+ "version": "2.0.4",
"source": {
"type": "git",
"url": "https://github.com/phar-io/manifest.git",
- "reference": "97803eca37d319dfa7826cc2437fc020857acb53"
+ "reference": "54750ef60c58e43759730615a392c31c80e23176"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/phar-io/manifest/zipball/97803eca37d319dfa7826cc2437fc020857acb53",
- "reference": "97803eca37d319dfa7826cc2437fc020857acb53",
+ "url": "https://api.github.com/repos/phar-io/manifest/zipball/54750ef60c58e43759730615a392c31c80e23176",
+ "reference": "54750ef60c58e43759730615a392c31c80e23176",
"shasum": ""
},
"require": {
"ext-dom": "*",
+ "ext-libxml": "*",
"ext-phar": "*",
"ext-xmlwriter": "*",
"phar-io/version": "^3.0.1",
@@ -1072,9 +1073,15 @@
"description": "Component for reading phar.io manifest information from a PHP Archive (PHAR)",
"support": {
"issues": "https://github.com/phar-io/manifest/issues",
- "source": "https://github.com/phar-io/manifest/tree/2.0.3"
+ "source": "https://github.com/phar-io/manifest/tree/2.0.4"
},
- "time": "2021-07-20T11:28:43+00:00"
+ "funding": [
+ {
+ "url": "https://github.com/theseer",
+ "type": "github"
+ }
+ ],
+ "time": "2024-03-03T12:33:53+00:00"
},
{
"name": "phar-io/version",
@@ -1129,16 +1136,16 @@
},
{
"name": "phpunit/php-code-coverage",
- "version": "10.1.11",
+ "version": "10.1.12",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/php-code-coverage.git",
- "reference": "78c3b7625965c2513ee96569a4dbb62601784145"
+ "reference": "842f72662d6b9edda84c4b6f13885fd9cd53dc63"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/78c3b7625965c2513ee96569a4dbb62601784145",
- "reference": "78c3b7625965c2513ee96569a4dbb62601784145",
+ "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/842f72662d6b9edda84c4b6f13885fd9cd53dc63",
+ "reference": "842f72662d6b9edda84c4b6f13885fd9cd53dc63",
"shasum": ""
},
"require": {
@@ -1195,7 +1202,7 @@
"support": {
"issues": "https://github.com/sebastianbergmann/php-code-coverage/issues",
"security": "https://github.com/sebastianbergmann/php-code-coverage/security/policy",
- "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/10.1.11"
+ "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/10.1.12"
},
"funding": [
{
@@ -1203,7 +1210,7 @@
"type": "github"
}
],
- "time": "2023-12-21T15:38:30+00:00"
+ "time": "2024-03-02T07:22:05+00:00"
},
{
"name": "phpunit/php-file-iterator",
@@ -1450,16 +1457,16 @@
},
{
"name": "phpunit/phpunit",
- "version": "10.5.10",
+ "version": "10.5.11",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/phpunit.git",
- "reference": "50b8e314b6d0dd06521dc31d1abffa73f25f850c"
+ "reference": "0d968f6323deb3dbfeba5bfd4929b9415eb7a9a4"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/50b8e314b6d0dd06521dc31d1abffa73f25f850c",
- "reference": "50b8e314b6d0dd06521dc31d1abffa73f25f850c",
+ "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/0d968f6323deb3dbfeba5bfd4929b9415eb7a9a4",
+ "reference": "0d968f6323deb3dbfeba5bfd4929b9415eb7a9a4",
"shasum": ""
},
"require": {
@@ -1531,7 +1538,7 @@
"support": {
"issues": "https://github.com/sebastianbergmann/phpunit/issues",
"security": "https://github.com/sebastianbergmann/phpunit/security/policy",
- "source": "https://github.com/sebastianbergmann/phpunit/tree/10.5.10"
+ "source": "https://github.com/sebastianbergmann/phpunit/tree/10.5.11"
},
"funding": [
{
@@ -1547,20 +1554,20 @@
"type": "tidelift"
}
],
- "time": "2024-02-04T09:07:51+00:00"
+ "time": "2024-02-25T14:05:00+00:00"
},
{
"name": "sebastian/cli-parser",
- "version": "2.0.0",
+ "version": "2.0.1",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/cli-parser.git",
- "reference": "efdc130dbbbb8ef0b545a994fd811725c5282cae"
+ "reference": "c34583b87e7b7a8055bf6c450c2c77ce32a24084"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/efdc130dbbbb8ef0b545a994fd811725c5282cae",
- "reference": "efdc130dbbbb8ef0b545a994fd811725c5282cae",
+ "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/c34583b87e7b7a8055bf6c450c2c77ce32a24084",
+ "reference": "c34583b87e7b7a8055bf6c450c2c77ce32a24084",
"shasum": ""
},
"require": {
@@ -1595,7 +1602,8 @@
"homepage": "https://github.com/sebastianbergmann/cli-parser",
"support": {
"issues": "https://github.com/sebastianbergmann/cli-parser/issues",
- "source": "https://github.com/sebastianbergmann/cli-parser/tree/2.0.0"
+ "security": "https://github.com/sebastianbergmann/cli-parser/security/policy",
+ "source": "https://github.com/sebastianbergmann/cli-parser/tree/2.0.1"
},
"funding": [
{
@@ -1603,7 +1611,7 @@
"type": "github"
}
],
- "time": "2023-02-03T06:58:15+00:00"
+ "time": "2024-03-02T07:12:49+00:00"
},
{
"name": "sebastian/code-unit",
@@ -1853,16 +1861,16 @@
},
{
"name": "sebastian/diff",
- "version": "5.1.0",
+ "version": "5.1.1",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/diff.git",
- "reference": "fbf413a49e54f6b9b17e12d900ac7f6101591b7f"
+ "reference": "c41e007b4b62af48218231d6c2275e4c9b975b2e"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/fbf413a49e54f6b9b17e12d900ac7f6101591b7f",
- "reference": "fbf413a49e54f6b9b17e12d900ac7f6101591b7f",
+ "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/c41e007b4b62af48218231d6c2275e4c9b975b2e",
+ "reference": "c41e007b4b62af48218231d6c2275e4c9b975b2e",
"shasum": ""
},
"require": {
@@ -1870,7 +1878,7 @@
},
"require-dev": {
"phpunit/phpunit": "^10.0",
- "symfony/process": "^4.2 || ^5"
+ "symfony/process": "^6.4"
},
"type": "library",
"extra": {
@@ -1908,7 +1916,7 @@
"support": {
"issues": "https://github.com/sebastianbergmann/diff/issues",
"security": "https://github.com/sebastianbergmann/diff/security/policy",
- "source": "https://github.com/sebastianbergmann/diff/tree/5.1.0"
+ "source": "https://github.com/sebastianbergmann/diff/tree/5.1.1"
},
"funding": [
{
@@ -1916,7 +1924,7 @@
"type": "github"
}
],
- "time": "2023-12-22T10:55:06+00:00"
+ "time": "2024-03-02T07:15:17+00:00"
},
{
"name": "sebastian/environment",
@@ -1984,16 +1992,16 @@
},
{
"name": "sebastian/exporter",
- "version": "5.1.1",
+ "version": "5.1.2",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/exporter.git",
- "reference": "64f51654862e0f5e318db7e9dcc2292c63cdbddc"
+ "reference": "955288482d97c19a372d3f31006ab3f37da47adf"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/64f51654862e0f5e318db7e9dcc2292c63cdbddc",
- "reference": "64f51654862e0f5e318db7e9dcc2292c63cdbddc",
+ "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/955288482d97c19a372d3f31006ab3f37da47adf",
+ "reference": "955288482d97c19a372d3f31006ab3f37da47adf",
"shasum": ""
},
"require": {
@@ -2050,7 +2058,7 @@
"support": {
"issues": "https://github.com/sebastianbergmann/exporter/issues",
"security": "https://github.com/sebastianbergmann/exporter/security/policy",
- "source": "https://github.com/sebastianbergmann/exporter/tree/5.1.1"
+ "source": "https://github.com/sebastianbergmann/exporter/tree/5.1.2"
},
"funding": [
{
@@ -2058,20 +2066,20 @@
"type": "github"
}
],
- "time": "2023-09-24T13:22:09+00:00"
+ "time": "2024-03-02T07:17:12+00:00"
},
{
"name": "sebastian/global-state",
- "version": "6.0.1",
+ "version": "6.0.2",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/global-state.git",
- "reference": "7ea9ead78f6d380d2a667864c132c2f7b83055e4"
+ "reference": "987bafff24ecc4c9ac418cab1145b96dd6e9cbd9"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/7ea9ead78f6d380d2a667864c132c2f7b83055e4",
- "reference": "7ea9ead78f6d380d2a667864c132c2f7b83055e4",
+ "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/987bafff24ecc4c9ac418cab1145b96dd6e9cbd9",
+ "reference": "987bafff24ecc4c9ac418cab1145b96dd6e9cbd9",
"shasum": ""
},
"require": {
@@ -2105,14 +2113,14 @@
}
],
"description": "Snapshotting of global state",
- "homepage": "http://www.github.com/sebastianbergmann/global-state",
+ "homepage": "https://www.github.com/sebastianbergmann/global-state",
"keywords": [
"global state"
],
"support": {
"issues": "https://github.com/sebastianbergmann/global-state/issues",
"security": "https://github.com/sebastianbergmann/global-state/security/policy",
- "source": "https://github.com/sebastianbergmann/global-state/tree/6.0.1"
+ "source": "https://github.com/sebastianbergmann/global-state/tree/6.0.2"
},
"funding": [
{
@@ -2120,7 +2128,7 @@
"type": "github"
}
],
- "time": "2023-07-19T07:19:23+00:00"
+ "time": "2024-03-02T07:19:19+00:00"
},
{
"name": "sebastian/lines-of-code",
@@ -2466,16 +2474,16 @@
},
{
"name": "theseer/tokenizer",
- "version": "1.2.2",
+ "version": "1.2.3",
"source": {
"type": "git",
"url": "https://github.com/theseer/tokenizer.git",
- "reference": "b2ad5003ca10d4ee50a12da31de12a5774ba6b96"
+ "reference": "737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/theseer/tokenizer/zipball/b2ad5003ca10d4ee50a12da31de12a5774ba6b96",
- "reference": "b2ad5003ca10d4ee50a12da31de12a5774ba6b96",
+ "url": "https://api.github.com/repos/theseer/tokenizer/zipball/737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2",
+ "reference": "737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2",
"shasum": ""
},
"require": {
@@ -2504,7 +2512,7 @@
"description": "A small library for converting tokenized PHP source code into XML and potentially other formats",
"support": {
"issues": "https://github.com/theseer/tokenizer/issues",
- "source": "https://github.com/theseer/tokenizer/tree/1.2.2"
+ "source": "https://github.com/theseer/tokenizer/tree/1.2.3"
},
"funding": [
{
@@ -2512,7 +2520,7 @@
"type": "github"
}
],
- "time": "2023-11-20T00:12:19+00:00"
+ "time": "2024-03-03T12:36:25+00:00"
}
],
"aliases": [],