diff --git a/Community/Tdarr_Plugin_00td_action_handbrake_ffmpeg_custom.js b/Community/Tdarr_Plugin_00td_action_handbrake_ffmpeg_custom.js index 26f3f1c..995603e 100644 --- a/Community/Tdarr_Plugin_00td_action_handbrake_ffmpeg_custom.js +++ b/Community/Tdarr_Plugin_00td_action_handbrake_ffmpeg_custom.js @@ -1,4 +1,3 @@ -// tdarrSkipTest const details = () => ({ id: 'Tdarr_Plugin_00td_action_handbrake_ffmpeg_custom', Stage: 'Pre-processing', @@ -85,8 +84,8 @@ const plugin = (file, librarySettings, inputs, otherArguments) => { processFile: false, preset: '', container: '', - handBrakeMode: false, - FFmpegMode: false, + handbrakeMode: false, + ffmpegMode: false, reQueueAfter: false, infoLog: '', }; diff --git a/tests/Community/Tdarr_Plugin_00td_action_handbrake_ffmpeg_custom.js b/tests/Community/Tdarr_Plugin_00td_action_handbrake_ffmpeg_custom.js new file mode 100644 index 0000000..41a2ff4 --- /dev/null +++ b/tests/Community/Tdarr_Plugin_00td_action_handbrake_ffmpeg_custom.js @@ -0,0 +1,66 @@ +/* eslint max-len: 0 */ +const run = require('../helpers/run'); + +const tests = [ + { + input: { + file: require('../sampleData/media/sampleH264_1.json'), + librarySettings: {}, + inputs: {}, + otherArguments: {}, + }, + output: { + processFile: true, + preset: ' -map 0 -c copy', + container: '.mkv', + handbrakeMode: false, + ffmpegMode: true, + reQueueAfter: true, + infoLog: 'File is being transcoded using custom arguments \n', + }, + }, + { + input: { + file: require('../sampleData/media/sampleH264_1.json'), + librarySettings: {}, + inputs: { + cli: 'handbrake', + arguments: '-Z "Very Fast 1080p30" --all-subtitles --all-audio', + container: 'mp4', + }, + otherArguments: {}, + }, + output: { + processFile: true, + preset: '-Z "Very Fast 1080p30" --all-subtitles --all-audio', + container: '.mp4', + handbrakeMode: true, + ffmpegMode: false, + reQueueAfter: true, + infoLog: 'File is being transcoded using custom arguments \n', + }, + }, + { + input: { + file: require('../sampleData/media/sampleH264_1.json'), + librarySettings: {}, + inputs: { + cli: 'ffmpeg', + arguments: '-c:v libx265 -crf 23 -ac 6 -c:a aac -preset veryfast', + container: 'mov', + }, + otherArguments: {}, + }, + output: { + processFile: true, + preset: '-c:v libx265 -crf 23 -ac 6 -c:a aac -preset veryfast', + container: '.mov', + handbrakeMode: false, + ffmpegMode: true, + reQueueAfter: true, + infoLog: 'File is being transcoded using custom arguments \n' + }, + }, +]; + +run(tests);