Add Tdarr_Plugin_00td_filter_break_stack_if_processed

This commit is contained in:
HaveAGitGat 2022-08-28 03:02:44 +01:00
parent 198ce71116
commit e17e44f290
2 changed files with 76 additions and 0 deletions

View file

@ -0,0 +1,40 @@
/* eslint max-len: 0 */
const _ = require('lodash');
const run = require('../helpers/run');
const tests = [
{
input: {
file: _.cloneDeep(require('../sampleData/media/sampleH265_1.json')),
librarySettings: {},
inputs: {},
otherArguments: {
originalLibraryFile: _.cloneDeep(require('../sampleData/media/sampleH265_1.json')),
},
},
output: {
processFile: true,
infoLog: 'File has not been processed yet. Continuing to next plugin.',
},
},
{
input: {
file: _.cloneDeep(require('../sampleData/media/sampleH265_1.json')),
librarySettings: {},
inputs: {},
otherArguments: {
originalLibraryFile: (() => {
const file = _.cloneDeep(require('../sampleData/media/sampleH265_1.json'));
file.file += 'test';
return file;
})(),
},
},
output: {
processFile: false,
infoLog: 'File has been processed, breaking out of plugin stack.',
},
},
];
run(tests);