summaryrefslogtreecommitdiff
path: root/test
AgeCommit message (Collapse)Author
2024-03-18Remove test for postgres < 11Mark Felder
2024-03-18Merge remote-tracking branch 'origin/develop' into instance_rulesmarcin mikołajczak
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
2024-03-18Merge branch 'develop' into 'bookmark-folders'lain
# Conflicts: # docs/development/API/differences_in_mastoapi_responses.md
2024-03-18Merge branch 'public-polls' into 'develop'lain
Expose nonAnonymous field from Smithereen polls See merge request pleroma/pleroma!3962
2024-03-17ActivityPub.Publisher: Don't try federating if a user doesn't have an inbox.Lain Soykaf
2024-03-17Merge branch 'force-mention' into 'develop'lain
Add ForceMention mrf See merge request pleroma/pleroma!4082
2024-03-15Merge branch 'backups' into 'develop'feld
Include following/followers in backups See merge request pleroma/pleroma!4085
2024-03-10Include following/followers in backupsmarcin mikołajczak
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
2024-03-08Merge remote-tracking branch 'origin/develop' into instance-contact-accountmarcin mikołajczak
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
2024-03-07Add testmarcin mikołajczak
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
2024-03-07Merge remote-tracking branch 'origin/develop' into link-verificationmarcin mikołajczak
2024-03-01Add ForceMention mrfmarcin mikołajczak
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
2024-03-01Allow to group bookmarks in foldersmarcin mikołajczak
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
2024-02-22Merge remote-tracking branch 'origin/develop' into HEADmarcin mikołajczak
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
2024-02-20StealEmojiPolicy: Sanitize shortcodesHaelwenn (lanodan) Monnier
Closes: https://git.pleroma.social/pleroma/pleroma/-/issues/3245
2024-02-15Merge branch 'websocket-refactor' into 'develop'feld
Websocket refactor to use Phoenix.Socket.Transport See merge request pleroma/pleroma!4064
2024-02-15Merge branch 'bugfix-ccworks' into 'develop'Haelwenn
Bugfix for ccworks AP bridge Closes #3234 See merge request pleroma/pleroma!4043
2024-02-14Remove invalid testMark Felder
It is not allowed to use the Sec-WebSocket-Protocol header for arbitrary values. This was possible due to the raw websocket handling we were doing with Cowboy, but Phoenix.Socket.Transport does not allow this as the value of this header is compared against a static list of subprotocols. https://hexdocs.pm/phoenix/Phoenix.Endpoint.html#socket/3-websocket-configuration Additionally I cannot find anywhere that we depended on this behavior. Setting the Sec-WebSocket-Protocol header does not appear to be a part of PleromaFE.
2024-02-06Pleroma.Web.RichMedia.Parser: Remove test-specific codepathsMark Felder
Also consolidate Tesla mocks into the HttpRequestMock module. Tests were not exercising the real codepaths. The Rich Media Preview only works with https, but most of these tests were only mocking http.
2024-02-05Ensure URLs with IP addresses for the host do not generate previewsMark Felder
2024-02-04Fix Rich Media Previews for updated activitiesMark Felder
The Rich Media Previews were not regenerated when a post was updated due to a cache invalidation issue. They are now cached by the activity id so they can be evicted with the other activity cache objects in the :scrubber_cache.
2024-01-31Merge remote-tracking branch 'origin/develop' into status-notification-typemarcin mikołajczak
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
2024-01-30Phoenix.Endpoint.Cowboy2Handler does not existMark Felder
This should have always failed as it would not be an existing atom. Unclear how it worked since the upgrade to Phoenix 1.6.
2024-01-30Revert "Pleroma.Web.AdminAPI.ConfigController: dialyzer error"Mark Felder
This reverts commit 60d89cb40455f9f70b683849dd95311975b0b6f7.
2024-01-29Pleroma.Web.MediaProxy.MediaProxyController: dialyzer errorsMark Felder
lib/pleroma/web/media_proxy/media_proxy_controller.ex:55:no_return Function handle_preview/2 has no local return. ________________________________________________________________________________ lib/pleroma/web/media_proxy/media_proxy_controller.ex:59:call The function call will not succeed. Pleroma.HTTP.request(<<72, 69, 65, 68>>, _media_proxy_url :: any(), [], [], [{:pool, :media}]) will never return since the success typing is: ( :delete | :get | :head | :options | :patch | :post | :put | :trace, binary(), any(), [{binary(), binary()}], Keyword.t() ) :: any() and the contract is ( method(), Pleroma.HTTP.Request.url(), String.t(), Pleroma.HTTP.Request.headers(), :elixir.keyword() ) :: {:ok, Tesla.Env.t()} | {:error, any()} ________________________________________________________________________________ lib/pleroma/web/media_proxy/media_proxy_controller.ex:95:unused_fun Function handle_preview/3 will never be called. ________________________________________________________________________________ lib/pleroma/web/media_proxy/media_proxy_controller.ex:111:unused_fun Function handle_png_preview/2 will never be called. ________________________________________________________________________________ lib/pleroma/web/media_proxy/media_proxy_controller.ex:134:unused_fun Function handle_jpeg_preview/2 will never be called. ________________________________________________________________________________ lib/pleroma/web/media_proxy/media_proxy_controller.ex:152:unused_fun Function handle_video_preview/2 will never be called. ________________________________________________________________________________ lib/pleroma/web/media_proxy/media_proxy_controller.ex:164:unused_fun Function drop_static_param_and_redirect/1 will never be called. ________________________________________________________________________________ lib/pleroma/web/media_proxy/media_proxy_controller.ex:173:unused_fun Function fallback_on_preview_error/2 will never be called. ________________________________________________________________________________ lib/pleroma/web/media_proxy/media_proxy_controller.ex:177:unused_fun Function put_preview_response_headers/1 will never be called. ________________________________________________________________________________ lib/pleroma/web/media_proxy/media_proxy_controller.ex:177:unused_fun Function put_preview_response_headers/2 will never be called. ________________________________________________________________________________ lib/pleroma/web/media_proxy/media_proxy_controller.ex:187:unused_fun Function thumbnail_max_dimensions/0 will never be called. ________________________________________________________________________________ lib/pleroma/web/media_proxy/media_proxy_controller.ex:196:unused_fun Function min_content_length_for_preview/0 will never be called. ________________________________________________________________________________ lib/pleroma/web/media_proxy/media_proxy_controller.ex:200:unused_fun Function media_preview_proxy_config/0 will never be called.
2024-01-29Merge branch 'deps-bump' into 'develop'Haelwenn
Bump dependencies See merge request pleroma/pleroma!4044
2024-01-27Pleroma.Web.AdminAPI.ConfigController: dialyzer errorMark Felder
lib/pleroma/web/admin_api/controllers/config_controller.ex:162:call The function call will not succeed. Phoenix.Controller.render( _conn :: %{:body_params => %{:configs => _, _ => _}, _ => _}, <<105, 110, 100, 101, 120, 46, 106, 115, 111, 110>>, %{:configs => [any()], :need_reboot => _} ) will never return since the success typing is: ( %Plug.Conn{ :adapter => {atom(), _}, :assigns => %{atom() => _}, :body_params => %Plug.Conn.Unfetched{:aspect => atom(), binary() => _}, :cookies => %Plug.Conn.Unfetched{:aspect => atom(), binary() => _}, :halted => boolean(), :host => binary(), :method => binary(), :owner => pid(), :params => %Plug.Conn.Unfetched{:aspect => atom(), binary() => _}, :path_info => [binary()], :path_params => %{binary() => binary() | [any()] | map()}, :port => char(), :private => %{atom() => _}, :query_params => %Plug.Conn.Unfetched{ :aspect => atom(), binary() => binary() | [any()] | map() }, :query_string => binary(), :remote_ip => {byte(), byte(), byte(), byte()} | {char(), char(), char(), char(), char(), char(), char(), char()}, :req_cookies => %Plug.Conn.Unfetched{:aspect => atom(), binary() => binary()}, :req_headers => [{_, _}], :request_path => binary(), :resp_body => nil | binary() | maybe_improper_list( binary() | maybe_improper_list(any(), binary() | []) | byte(), binary() | [] ), :resp_cookies => %{binary() => map()}, :resp_headers => [{_, _}], :scheme => :http | :https, :script_name => [binary()], :secret_key_base => nil | binary(), :state => :chunked | :file | :sent | :set | :set_chunked | :set_file | :unset | :upgraded, :status => nil | non_neg_integer() }, atom() | binary(), atom() | binary() | [{_, _}] | map() ) :: %Plug.Conn{ :adapter => {atom(), _}, :assigns => %{atom() => _}, :body_params => %Plug.Conn.Unfetched{:aspect => atom(), binary() => _}, :cookies => %Plug.Conn.Unfetched{:aspect => atom(), binary() => _}, :halted => boolean(), :host => binary(), :method => binary(), :owner => pid(), :params => %Plug.Conn.Unfetched{:aspect => atom(), binary() => _}, :path_info => [binary()], :path_params => %{binary() => binary() | [any()] | map()}, :port => char(), :private => %{atom() => _}, :query_params => %Plug.Conn.Unfetched{ :aspect => atom(), binary() => binary() | [any()] | map() }, :query_string => binary(), :remote_ip => {byte(), byte(), byte(), byte()} | {char(), char(), char(), char(), char(), char(), char(), char()}, :req_cookies => %Plug.Conn.Unfetched{:aspect => atom(), binary() => binary()}, :req_headers => [{_, _}], :request_path => binary(), :resp_body => nil | binary() | maybe_improper_list( binary() | maybe_improper_list(any(), binary() | []) | byte(), binary() | [] ), :resp_cookies => %{binary() => map()}, :resp_headers => [{_, _}], :scheme => :http | :https, :script_name => [binary()], :secret_key_base => nil | binary(), :state => :sent, :status => nil | non_neg_integer() } and the contract is (Plug.Conn.t(), binary() | atom(), Keyword.t() | map()) :: Plug.Conn.t()
2024-01-26Pleroma.Signature: dialyzer errorMark Felder
lib/pleroma/signature.ex:30:pattern_match The pattern can never match the type. Pattern: %{<<97, 112, 95, 105, 100>> => _ap_id} Type: {:error, _} | {:ok, map()}
2024-01-26RichMedia.Parser.TTL.AwsSignedUrl: dialyzer fixMark Felder
lib/pleroma/web/rich_media/parser/ttl/aws_signed_url.ex:9:callback_type_mismatch Type mismatch for @callback ttl/2 in Pleroma.Web.RichMedia.Parser.TTL behaviour. Expected type: nil | integer() Actual type: {:error, <<_::64, _::size(8)>>} | {:ok, integer()}
2024-01-26Credo.Check.Readability.PredicateFunctionNamesMark Felder
This check was recently improved in Credo and it does make sense for readability. The offending functions in Pleroma have been renamed and a couple missing the ? suffix have been fixed as well.
2024-01-26Test incoming federation from Convergence AP BridgeHaelwenn (lanodan) Monnier
2024-01-26Maps: Add filter_empty_values/1Haelwenn (lanodan) Monnier
2024-01-21Merge branch 'develop' into 'public-polls'Haelwenn
# Conflicts: # docs/development/API/differences_in_mastoapi_responses.md
2024-01-19Merge branch 'handle_object_fetch_failures' into 'develop'Haelwenn
Handle object fetch failures gracefully See merge request pleroma/pleroma!4015
2024-01-17Merge branch 'otp26' into 'develop'Haelwenn
OTP26 support See merge request pleroma/pleroma!4025
2024-01-15Skip tests on MacOS/Darwin that have always failedMark Felder
2024-01-16Pleroma.Web.MastodonAPI.SubscriptionControllerTest: disable async and use ↵Mark Felder
on_exit/1 to ensure web push config gets restored
2024-01-15Fix StatusController test by using the get_query_parameter/2 helper to ↵Mark Felder
reliably retrieve the max_id value
2024-01-15Add Pleroma.Test.Helpers.get_query_parameter/2 to retrieve specific query ↵Mark Felder
parameter values
2024-01-15Fix ChatController tests validating prev/next URLs by sorting the query ↵Mark Felder
parameters before comparison
2024-01-15Add Pleroma.Support.Helpers.uri_query_sort/1 for easy sorting of a URL's ↵Mark Felder
query parameters
2024-01-15Merge branch 'mrf-regex-error' into 'develop'Haelwenn
MRF: Log sensible regex error for subdomain_match See merge request pleroma/pleroma!4026
2024-01-15Merge branch 'mrf-steal-emoji-extname' into 'develop'Haelwenn
MRF.StealEmojiPolicy: Properly add fallback extension to filenames missing one See merge request pleroma/pleroma!4029
2024-01-14Allow the Remote Fetcher to attempt fetching an unreachable instanceMark Felder
2024-01-13Merge branch 'nil-contentMap' into 'develop'tusooa
Support objects with a nil contentMap (firefish) Closes #3231 See merge request pleroma/pleroma!4030
2024-01-11Add test to validate shared inboxes are used when multiple recipients from ↵Mark Felder
the same instance are recipients
2024-01-11Support objects with a nil contentMap (firefish)Haelwenn (lanodan) Monnier
Closes: https://git.pleroma.social/pleroma/pleroma/-/issues/3231
2024-01-07MRF.StealEmojiPolicy: Properly add fallback extension to filenames missing oneHaelwenn (lanodan) Monnier
2024-01-07Fix testsEkaterina Vaartis
2024-01-02MRF: Log sensible error for subdomains_regexHaelwenn (lanodan) Monnier