1
0
mirror of https://gitlab.crans.org/nounous/ghostream.git synced 2024-12-22 20:52:20 +00:00

FFMPEG is a dependency, don't check if it is installed

This commit is contained in:
Yohann D'ANELLO 2020-10-14 19:04:50 +02:00
parent e56b21b819
commit e5f4c3a7e6

View File

@ -11,20 +11,6 @@ import (
// TestServeSRT Serve a SRT server, stream content during 5 seconds and ensure that it is well received // TestServeSRT Serve a SRT server, stream content during 5 seconds and ensure that it is well received
func TestForwardStream(t *testing.T) { func TestForwardStream(t *testing.T) {
// Check that ffmpeg is installed
which := exec.Command("which", "ffmpeg")
if err := which.Start(); err != nil {
t.Fatal("Error while checking if ffmpeg got installed:", err)
}
state, err := which.Process.Wait()
if err != nil {
t.Fatal("Error while checking if ffmpeg got installed:", err)
}
if state.ExitCode() != 0 {
// FFMPEG is not installed
t.Skip("WARNING: FFMPEG is not installed. Skipping stream test")
}
// Start virtual RTMP server with ffmpeg // Start virtual RTMP server with ffmpeg
forwardedFfmpeg := exec.Command("ffmpeg", "-hide_banner", "-loglevel", "error", forwardedFfmpeg := exec.Command("ffmpeg", "-hide_banner", "-loglevel", "error",
"-y", // allow overwrite /dev/null "-y", // allow overwrite /dev/null