From 6d6cedea0453f94946eeb5bf79a1c6ad59f1f87b Mon Sep 17 00:00:00 2001 From: HaveAGitGat <43864057+HaveAGitGat@users.noreply.github.com> Date: Mon, 23 May 2022 06:46:43 +0100 Subject: [PATCH] Add Tdarr_Plugin_x7ab_Remove_Subs test --- Community/Tdarr_Plugin_x7ab_Remove_Subs.js | 1 - .../Tdarr_Plugin_x7ab_Remove_Subs.js | 42 +++++++++++++++++++ 2 files changed, 42 insertions(+), 1 deletion(-) create mode 100644 tests/Community/Tdarr_Plugin_x7ab_Remove_Subs.js diff --git a/Community/Tdarr_Plugin_x7ab_Remove_Subs.js b/Community/Tdarr_Plugin_x7ab_Remove_Subs.js index 3bf03de..7bd12ff 100644 --- a/Community/Tdarr_Plugin_x7ab_Remove_Subs.js +++ b/Community/Tdarr_Plugin_x7ab_Remove_Subs.js @@ -1,5 +1,4 @@ /* eslint-disable */ -// tdarrSkipTest const details = () => { return { id: "Tdarr_Plugin_x7ab_Remove_Subs", diff --git a/tests/Community/Tdarr_Plugin_x7ab_Remove_Subs.js b/tests/Community/Tdarr_Plugin_x7ab_Remove_Subs.js new file mode 100644 index 0000000..9eca971 --- /dev/null +++ b/tests/Community/Tdarr_Plugin_x7ab_Remove_Subs.js @@ -0,0 +1,42 @@ +/* eslint max-len: 0 */ +const _ = require('lodash'); +const run = require('../helpers/run'); + +const tests = [ + { + input: { + file: _.cloneDeep(require('../sampleData/media/sampleH264_1.json')), + librarySettings: {}, + inputs: {}, + otherArguments: {}, + }, + output: { + processFile: false, + preset: '', + container: '.mp4', + handBrakeMode: false, + FFmpegMode: true, + reQueueAfter: false, + infoLog: '☑File has no subs \n☑File meets conditions! \n', + }, + }, + { + input: { + file: _.cloneDeep(require('../sampleData/media/sampleH264_2.json')), + librarySettings: {}, + inputs: {}, + otherArguments: {}, + }, + output: { + processFile: true, + preset: ',-sn -map 0 -c copy', + container: '.mkv', + handBrakeMode: false, + FFmpegMode: true, + reQueueAfter: true, + infoLog: '☒File has subs \n', + }, + }, +]; + +run(tests);