* diskspeed: follow pylint's advice, and more pytesting
* diskspeed: improved hint, catch relevant exceptions
* diskspeed: lower tun time to 0.5 s (as we run it twice)
* diskspeed: make black and pylint happier
* Delete somefile.txt
* Add base implementation of SSDP util
* SSDP+XML: working setup #1
* SSDP+XML: with socket ... as sock
* SSDP+XML: unique UUIDs
* SSDP+XML: simpler constructions of XML URL
* SSDP+XML: cleaner SSDP and XML, steady UUID in XML, better logging
* SSDP+XML: UUIDs into __init__(). Better, innit?
* SSDP+XML: Make black happy again
* SSDP+XML: Make black happy again ... now for interface.py
* SSDP+XML: creation of SSDP message and XML to __init__()
* SSDP+XML: changes based on feedback
* SSDP+XML: no more SABnzbd references in ssdp.py. No network is OK now.
* SSDP+XML: references to specs for SSDP and the XML
Co-authored-by: Safihre <safihre@sabnzbd.org>
* fix deprecation warning in sabnews regex
* enable text, xml returns from get_api_result
* add api tests
* add functional api tests
* add tavern.yaml files to test data
* explicitly add lxml to work around pip dependency issues
* prevent pytest from picking up the tavern files
* Revert "fix deprecation warning in sabnews regex"
This reverts commit 4f0b7131e7.
* address minor issues
* integrate fixtures into conftest
* black :/
* harden queue repair test
* try a workaround for extremely slow test runs on windoze
* Correct server detection in functional tests
* move scripts dir inside SAB_CACHE_DIR
* also relocate the generated script
Co-authored-by: Safihre <safihre@sabnzbd.org>
SMTP protocol dictates that all lines are supposed to be separated
with CRLF and not LF (even on LF-based systems). This change ensures
that even if the original byte string message is using `\n` for line
separators, the SMTP protocol will still work properly.
This resolves sabnzbd#1669
Fix code formatting
* randomize age for generated nzb files
Useful for testing queue sorting function of the api. Timestamp values are randomly chosen between september '93 and now.
* Sigh.
* only replace the first occurence of "script_"
Use of str.replace() without a count replaces all occurences. As a result, scripts with filenames such as "my_script_for_sab.py" would be mangled when trying to set them as action on queue completion.
* also modify the check of the action var