Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def test_validate_ffmpeg(paths):
FFmpeg_path = ''
if os.name == 'nt':
FFmpeg_path += os.path.join(paths, 'ffmpeg-latest-{}-static/bin/ffmpeg.exe'.format(getBitmode()))
else:
FFmpeg_path += os.path.join(paths, 'ffmpeg-4.1.3-{}-static/ffmpeg'.format(getBitmode(False)))
try:
output = validate_ffmpeg(FFmpeg_path, logging = True)
if paths != 'wrong_test_path':
assert bool(output), "Validation Test failed at path: {}".format(FFmpeg_path)
except Exception as e:
if paths == 'wrong_test_path':
pass
else:
pytest.fail(str(e))