Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: test/compiled/Filter.cpp

Issue 29595633: Issue 5870 - Implement the new ElemHideEmulation filter type (Closed) Base URL: https://hg.adblockplus.org/adblockpluscore/
Patch Set: Review comments Created Jan. 30, 2018, 10:52 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « meson.build ('k') | test/elemHideEmulation.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/compiled/Filter.cpp
===================================================================
new file mode 100644
--- /dev/null
+++ b/test/compiled/Filter.cpp
@@ -0,0 +1,14 @@
+
hub 2018/01/30 23:12:01 I have an update with the license header I forgot.
+
+#include "gtest/gtest.h"
+#include "compiled/String.h"
+#include "compiled/filter/Filter.h"
+
+TEST(TestFilter, testFromText)
+{
+ OwnedString t(u"www.example.com#@#:-abp-properties(foo)"_str);
+ DependentString text(t);
+
+ FilterPtr filter(Filter::FromText(text));
+ EXPECT_EQ(filter->GetText(), u"www.example.com#@#:-abp-properties(foo)"_str);
+}
hub 2018/01/30 23:12:01 and more comprehensive tests for this part. This w
« no previous file with comments | « meson.build ('k') | test/elemHideEmulation.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld