mirror of
https://github.com/bybrooklyn/alchemist.git
synced 2026-04-18 01:43:34 -04:00
Test Fixtures
This directory contains small video files for testing the FFmpeg integration.
Generated Files
The following test fixtures are generated by generate_fixtures.sh (or manually via FFmpeg):
test_h264.mp4- 1-second H.264 video (320x240, 30fps)test_hevc.mp4- 1-second HEVC video (320x240, 30fps)test_h264_with_audio.mp4- 1-second H.264 video with AAC audiotest_h264_with_subtitles.mkv- 1-second H.264 video with SRT subtitlestest_subtitle.srt- Simple SRT subtitle filedb_v0_2_5.sqlite- Pre-upgrade SQLite fixture used by the DB migration compatibility test
Usage
These fixtures are used by the integration tests in:
tests/integration_ffmpeg.rs- Full pipeline tests (currently disabled due to server deps)tests/integration_ffmpeg_minimal.rs- Minimal analyzer teststests/integration_db_upgrade.rs- Upgrade test that migrates a seededv0.2.5database to the current schema
Regenerating Fixtures
If you need to regenerate the test files:
cd tests/fixtures
# H.264 video
ffmpeg -f lavfi -i testsrc=duration=1:size=320x240:rate=30 -c:v libx264 -pix_fmt yuv420p -y test_h264.mp4
# HEVC video
ffmpeg -f lavfi -i testsrc=duration=1:size=320x240:rate=30 -c:v libx265 -pix_fmt yuv420p -y test_hevc.mp4
# H.264 with audio
ffmpeg -f lavfi -i testsrc=duration=1:size=320x240:rate=30 -f lavfi -i sine=frequency=1000:duration=1 -c:v libx264 -c:a aac -shortest -pix_fmt yuv420p -y test_h264_with_audio.mp4
# Subtitle file
echo -e "1\n00:00:00,000 --> 00:00:01,000\nTest subtitle" > test_subtitle.srt
# H.264 with subtitles
ffmpeg -f lavfi -i testsrc=duration=1:size=320x240:rate=30 -i test_subtitle.srt -c:v libx264 -c:s srt -map 0 -map 1 -shortest -pix_fmt yuv420p -y test_h264_with_subtitles.mkv
File Sizes
All test files are deliberately small (< 20KB each) to keep the repository lightweight while providing adequate coverage for FFmpeg integration testing.