mirror of
https://git.pleroma.social/pleroma/pleroma.git
synced 2024-12-23 00:26:30 +00:00
Activate test for object validator that has not been running
This commit is contained in:
parent
11c520607f
commit
8076deeeb4
1 changed files with 3 additions and 2 deletions
|
@ -6,15 +6,16 @@ defmodule Pleroma.EctoType.ActivityPub.ObjectValidators.BareUriTest do
|
||||||
use Pleroma.DataCase, async: true
|
use Pleroma.DataCase, async: true
|
||||||
|
|
||||||
alias Pleroma.EctoType.ActivityPub.ObjectValidators.BareUri
|
alias Pleroma.EctoType.ActivityPub.ObjectValidators.BareUri
|
||||||
|
alias Pleroma.EctoType.ActivityPub.ObjectValidators.SafeText
|
||||||
|
|
||||||
test "diaspora://" do
|
test "diaspora://" do
|
||||||
text = "diaspora://alice@fediverse.example/post/deadbeefdeadbeefdeadbeefdeadbeef"
|
text = "diaspora://alice@fediverse.example/post/deadbeefdeadbeefdeadbeefdeadbeef"
|
||||||
assert {:ok, text} = BareUri.cast(text)
|
assert {:ok, ^text} = BareUri.cast(text)
|
||||||
end
|
end
|
||||||
|
|
||||||
test "nostr:" do
|
test "nostr:" do
|
||||||
text = "nostr:note1gwdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeef"
|
text = "nostr:note1gwdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeefdeadbeef"
|
||||||
assert {:ok, text} = BareUri.cast(text)
|
assert {:ok, ^text} = BareUri.cast(text)
|
||||||
end
|
end
|
||||||
|
|
||||||
test "errors for non-URIs" do
|
test "errors for non-URIs" do
|
Loading…
Reference in a new issue