mirror of
https://git.pleroma.social/pleroma/pleroma.git
synced 2024-11-20 08:30:59 +00:00
6b7b443ff9
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.
46 lines
1 KiB
Elixir
46 lines
1 KiB
Elixir
# Pleroma: A lightweight social networking server
|
|
# Copyright © 2017-2022 Pleroma Authors <https://pleroma.social/>
|
|
# SPDX-License-Identifier: AGPL-3.0-only
|
|
|
|
defmodule Pleroma.CachexProxy do
|
|
@behaviour Pleroma.Caching
|
|
|
|
@impl true
|
|
defdelegate get!(cache, key), to: Cachex
|
|
|
|
@impl true
|
|
defdelegate stream!(cache, key), to: Cachex
|
|
|
|
@impl true
|
|
defdelegate put(cache, key, value, options), to: Cachex
|
|
|
|
@impl true
|
|
defdelegate put(cache, key, value), to: Cachex
|
|
|
|
@impl true
|
|
defdelegate get_and_update(cache, key, func), to: Cachex
|
|
|
|
@impl true
|
|
defdelegate get(cache, key), to: Cachex
|
|
|
|
@impl true
|
|
defdelegate fetch!(cache, key, func), to: Cachex
|
|
|
|
@impl true
|
|
defdelegate fetch(cache, key, func), to: Cachex
|
|
|
|
@impl true
|
|
defdelegate expire_at(cache, str, num), to: Cachex
|
|
|
|
@impl true
|
|
defdelegate expire(cache, str, num), to: Cachex
|
|
|
|
@impl true
|
|
defdelegate exists?(cache, key), to: Cachex
|
|
|
|
@impl true
|
|
defdelegate del(cache, key), to: Cachex
|
|
|
|
@impl true
|
|
defdelegate execute!(cache, func), to: Cachex
|
|
end
|