From a88921e71b7832216dedff7d2feba902390f23e5 Mon Sep 17 00:00:00 2001 From: Aqua-sama Date: Fri, 17 Apr 2020 18:08:31 +0300 Subject: smolblok: rewrite filtermanager --- staging/smolblok/test/main.cpp | 18 ++++++++++++++++++ staging/smolblok/test/sample-filters.txt | 4 ++++ 2 files changed, 22 insertions(+) create mode 100644 staging/smolblok/test/main.cpp create mode 100644 staging/smolblok/test/sample-filters.txt (limited to 'staging/smolblok/test') diff --git a/staging/smolblok/test/main.cpp b/staging/smolblok/test/main.cpp new file mode 100644 index 0000000..11f2b80 --- /dev/null +++ b/staging/smolblok/test/main.cpp @@ -0,0 +1,18 @@ +#include "filtermanager.hpp" + +int main(int argc, char **argv) +{ + if(argc != 2) { + qDebug("Usage: %s filters.txt", argv[0]); + return 77; + } + + FilterManager sub; + const auto r = sub.installSubscriptions(argv[1]); + + if(!r.success) { + return 77; + } + + return 0; +} diff --git a/staging/smolblok/test/sample-filters.txt b/staging/smolblok/test/sample-filters.txt new file mode 100644 index 0000000..574501f --- /dev/null +++ b/staging/smolblok/test/sample-filters.txt @@ -0,0 +1,4 @@ +[easylist-noelemhide] +File = easylist_noelemhide.txt +Href = https://easylist-downloads.adblockplus.org/easylist_noelemhide.txt + -- cgit v1.2.1