Add Tdarr_Plugin_00td_filter_by_size test

This commit is contained in:
HaveAGitGat 2022-05-21 15:37:01 +01:00
parent 77692935c5
commit fc2b3f9b27
2 changed files with 64 additions and 1 deletions

View file

@ -1,4 +1,3 @@
// tdarrSkipTest
const details = () => ({
id: 'Tdarr_Plugin_00td_filter_by_size',
Stage: 'Pre-processing',

View file

@ -0,0 +1,64 @@
/* 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,
infoLog: 'File is within lower and upper bound size limits. Moving to next plugin.',
},
},
{
input: {
file: require('../sampleData/media/sampleH264_1.json'),
librarySettings: {},
inputs: {
upperBound: 0.5,
lowerBound: 0,
},
otherArguments: {},
},
output: {
processFile: false,
infoLog: 'File is not within lower and upper bound size limits. Breaking out of plugin stack.',
},
},
{
input: {
file: require('../sampleData/media/sampleH264_1.json'),
librarySettings: {},
inputs: {
upperBound: 2,
lowerBound: 0,
},
otherArguments: {},
},
output: {
processFile: true,
infoLog: 'File is within lower and upper bound size limits. Moving to next plugin.',
},
},
{
input: {
file: require('../sampleData/media/sampleH264_1.json'),
librarySettings: {},
inputs: {
upperBound: 4,
lowerBound: 2,
},
otherArguments: {},
},
output: {
processFile: false,
infoLog: 'File is not within lower and upper bound size limits. Breaking out of plugin stack.',
},
},
];
run(tests);