test: hold one Radarr FHD release for native scan PoC
This commit is contained in:
parent
2929014b5c
commit
8c36977d63
1 changed files with 29 additions and 1 deletions
|
|
@ -61,7 +61,8 @@ const result = context.__exports.Script(
|
||||||
scenario.scopeRoot,
|
scenario.scopeRoot,
|
||||||
false,
|
false,
|
||||||
true,
|
true,
|
||||||
300
|
300,
|
||||||
|
scenario.pocHoldRelease || ''
|
||||||
);
|
);
|
||||||
process.stdout.write(JSON.stringify({result, calls}));
|
process.stdout.write(JSON.stringify({result, calls}));
|
||||||
"""
|
"""
|
||||||
|
|
@ -262,6 +263,33 @@ class RadarrImportSafetyTests(unittest.TestCase):
|
||||||
self.assertEqual(result["result"], 1)
|
self.assertEqual(result["result"], 1)
|
||||||
command = next(call for call in result["calls"] if call["type"] == "command")
|
command = next(call for call in result["calls"] if call["type"] == "command")
|
||||||
self.assertEqual(command["body"]["files"][0]["movieId"], 7331)
|
self.assertEqual(command["body"]["files"][0]["movieId"], 7331)
|
||||||
|
def test_poc_hold_leaves_exact_release_for_external_native_scan(self):
|
||||||
|
release = "The.Ritual.2017.German.DL.1080p.WEB.x264.iNTERNAL-BiGiNT"
|
||||||
|
exact = f"/tdarr/converted/video/{release}/{release}.mkv"
|
||||||
|
result = run_script(
|
||||||
|
{
|
||||||
|
"releaseTitle": release,
|
||||||
|
"exactPath": exact,
|
||||||
|
"scopeRoot": "/tdarr/converted/video/",
|
||||||
|
"pocHoldRelease": release,
|
||||||
|
"queueResponse": {"records": [{"title": release, "movieId": 6676}]},
|
||||||
|
"historyResponse": {
|
||||||
|
"records": [
|
||||||
|
{
|
||||||
|
"sourceTitle": release,
|
||||||
|
"movieId": 6676,
|
||||||
|
"downloadId": "poc-nzo-id",
|
||||||
|
"eventType": "grabbed",
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"candidates": [],
|
||||||
|
}
|
||||||
|
)
|
||||||
|
|
||||||
|
self.assertEqual(result["result"], 1)
|
||||||
|
commands = [call for call in result["calls"] if call["type"] == "command"]
|
||||||
|
self.assertEqual(commands, [])
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue