Skip to content

Commit

Permalink
[Test] Fix selectors test
Browse files Browse the repository at this point in the history
  • Loading branch information
vstakhov committed Sep 13, 2020
1 parent 43fda17 commit 41abce2
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions test/lua/unit/selectors.lua
Expand Up @@ -69,7 +69,7 @@ context("Selectors test", function()

["digest"] = {
selector = "digest",
expect = {"f46ccafe448fe4d7b46076938749695e"}
expect = {"1ac109c58a7d0f5f532100ac14e9f4d9"}
},

["user"] = {
Expand Down Expand Up @@ -184,19 +184,19 @@ context("Selectors test", function()

["urls"] = {
selector = "urls",
expect = {{"http://example.net"}}},
expect = {{"http://subdomain.example.net"}}},

["emails"] = {
selector = "emails",
expect = {{"test@example.net"}}},

["specific_urls"] = {
selector = "specific_urls({limit = 1})",
expect = {{"http://example.net"}}},
expect = {{"http://subdomain.example.net"}}},

["specific_urls + emails"] = {
selector = "specific_urls({need_emails = true, limit = 2})",
expect = {{"test@example.net", "http://example.net"}}},
expect = {{"test@example.net", "http://subdomain.example.net"}}},

["specific_urls + emails limit"] = {
selector = "specific_urls({need_emails = true, limit = 1})",
Expand Down Expand Up @@ -224,7 +224,7 @@ context("Selectors test", function()

["get_host"] = {
selector = "urls:get_host",
expect = {{"example.net"}}},
expect = {{"subdomain.example.net"}}},

["get_tld"] = {
selector = "urls:get_tld",
Expand Down Expand Up @@ -398,7 +398,7 @@ Hello world
Content-Type: text/html; charset="utf-8"
<html><body>
<a href="http://example.net">http://example.net</a>
<a href="http://subdomain.example.net">http://subdomain.example.net</a>
<a href="mailto:test@example.net">mail me</a>
</html>
Expand Down

0 comments on commit 41abce2

Please sign in to comment.