mirror of
https://github.com/idanoo/autobrr
synced 2025-07-23 16:59:12 +00:00
feat(definitions): add expectations for test lines (#1257)
* factor out test helpers * refactor, add tests for animebytes * revert test refactor * better name * change format, migrate some examples * migrated remaining test cases * add comment about `Test` vs `Tests` * refactor * reorder expectations to match vars * generate * turn on strict unmarshalling, remove old `Test` from schema * start modifying actual definitions * done with the As * Bs * C, D * E, F * G, H, I, ... L * M, N * O, P * R * bonus error. without this, pattern/vars disagreement can panic. * S * T, U * X.. Now we know our ABCs next time won't you sing with meeeee * fix another test * another driveby change * be less strict parsing custom definitions * fix(definitions): load custom definitions --------- Co-authored-by: ze0s <ze0s@riseup.net>
This commit is contained in:
parent
e842a7bd42
commit
fef0da5711
83 changed files with 1887 additions and 565 deletions
|
@ -11,7 +11,7 @@ protocol: torrent
|
|||
supports:
|
||||
- irc
|
||||
- rss
|
||||
source: gazelle
|
||||
# source: gazelle
|
||||
settings:
|
||||
- name: torrent_pass
|
||||
type: secret
|
||||
|
@ -57,10 +57,41 @@ irc:
|
|||
parse:
|
||||
type: single
|
||||
lines:
|
||||
- test:
|
||||
- "[Feature Film] Tremar (1897) [H264 / MKV / Blu-ray / 1080p / DTS / Subs / Freeleech! / Filename: Tremar.1897.1080p.BluRay.DTS.x264-GROUP] [12.84 GiB - Uploader: user] https://anthelion.me/torrents.php?action=download&id=110 - action,horror,subtitles"
|
||||
- "[Feature Film] Circus Du (1928) [H264 / MKV / Blu-ray / 1080p / AC3 / Scene / Freeleech! / Filename: Circus.Du.1928.1080p.BluRay.ACC.x264-GROUP] [8.24 GiB - Uploader: anon] https://anthelion.me/torrents.php?action=download&id=85 - comedy,romance"
|
||||
- "[Feature Film] Judo (1918) [H264 / MKV / Blu-ray / 1080p / DTS / Subs / Freeleech! / Filename: Judo.1918.1080p.BluRay.DTS.x264-GROUP] [7.40 GiB - Uploader: user1] https://anthelion.me/torrents.php?action=download&id=117 - crime,drama,thriller,action,subtitles"
|
||||
- tests:
|
||||
- line: '[Feature Film] Tremar (1897) [H264 / MKV / Blu-ray / 1080p / DTS / Subs / Freeleech! / Filename: Tremar.1897.1080p.BluRay.DTS.x264-GROUP] [12.84 GiB - Uploader: user] https://anthelion.me/torrents.php?action=download&id=110 - action,horror,subtitles'
|
||||
expect:
|
||||
category: Feature Film
|
||||
year: "1897"
|
||||
releaseTags: H264 / MKV / Blu-ray / 1080p / DTS / Subs / Freeleech!
|
||||
torrentName: Tremar.1897.1080p.BluRay.DTS.x264-GROUP
|
||||
torrentSize: 12.84 GiB
|
||||
uploader: user
|
||||
baseUrl: https://anthelion.me/
|
||||
torrentId: "110"
|
||||
tags: action,horror,subtitles
|
||||
- line: '[Feature Film] Circus Du (1928) [H264 / MKV / Blu-ray / 1080p / AC3 / Scene / Freeleech! / Filename: Circus.Du.1928.1080p.BluRay.ACC.x264-GROUP] [8.24 GiB - Uploader: anon] https://anthelion.me/torrents.php?action=download&id=85 - comedy,romance'
|
||||
expect:
|
||||
category: Feature Film
|
||||
year: "1928"
|
||||
releaseTags: H264 / MKV / Blu-ray / 1080p / AC3 / Scene / Freeleech!
|
||||
torrentName: Circus.Du.1928.1080p.BluRay.ACC.x264-GROUP
|
||||
torrentSize: 8.24 GiB
|
||||
uploader: anon
|
||||
baseUrl: https://anthelion.me/
|
||||
torrentId: "85"
|
||||
tags: comedy,romance
|
||||
- line: '[Feature Film] Judo (1918) [H264 / MKV / Blu-ray / 1080p / DTS / Subs / Freeleech! / Filename: Judo.1918.1080p.BluRay.DTS.x264-GROUP] [7.40 GiB - Uploader: user1] https://anthelion.me/torrents.php?action=download&id=117 - crime,drama,thriller,action,subtitles'
|
||||
expect:
|
||||
category: Feature Film
|
||||
year: "1918"
|
||||
releaseTags: H264 / MKV / Blu-ray / 1080p / DTS / Subs / Freeleech!
|
||||
torrentName: Judo.1918.1080p.BluRay.DTS.x264-GROUP
|
||||
torrentSize: 7.40 GiB
|
||||
uploader: user1
|
||||
baseUrl: https://anthelion.me/
|
||||
torrentId: "117"
|
||||
tags: crime,drama,thriller,action,subtitles
|
||||
|
||||
pattern: '\[(.*?)\] .* \((.*)\) \[(.*) \/ Filename: (.*)\] \[(.*) - Uploader: (.*)\] (https?\:\/\/.*\/).*id=(\d+).* - (.*)'
|
||||
vars:
|
||||
- category
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue