Skip to content

Commit

Permalink
check other whenwhere url
Browse files Browse the repository at this point in the history
Signed-off-by: Connor Rigby <[email protected]>
  • Loading branch information
ConnorRigby committed Jun 7, 2024
1 parent 1077eed commit dcea8ee
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
keys:
- v1-mix-cache-<< parameters.tag >>-{{ checksum "mix.lock" }}
- run: mix deps.get
- run: mix test --exclude requires_ipv6 --exclude whenwhere
- run: mix test --exclude requires_ipv6
- when:
condition:
matches: { <<: *latest, value: << parameters.tag >> }
Expand Down
14 changes: 14 additions & 0 deletions test/vintage_net/connectivity/when_where_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,18 @@ defmodule VintageNet.Connectivity.WhenWhereTest do
_ -> false
end)
end

test "when/where" do
ifname = Utils.get_ifname_for_tests()

{:ok, normalized_whenwhere} =
WhenWhere.normalize({WhenWhere, url: "http://dnlawqcegshx3.cloudfront.net"})

assert {:ok, {:internet, properties}} = WhenWhere.check(ifname, normalized_whenwhere)

assert Enum.find(properties, fn
{["timestamp"], _} -> true
_ -> false
end)
end
end

0 comments on commit dcea8ee

Please sign in to comment.