[Enhancement] Custom media lifecycle scripts (#219)
* Namespaced notification modules under lifecycle * Added a JSON encoder for all the main model types * Added startup task to create user script file * Hook up user script event to media download * Hooked up media deletion user script * Added jq to docker deps * Updated README
This commit is contained in:
@@ -1,11 +1,14 @@
|
||||
defmodule PinchflatWeb.MediaItemControllerTest do
|
||||
use PinchflatWeb.ConnCase
|
||||
|
||||
import Mox
|
||||
import Pinchflat.MediaFixtures
|
||||
|
||||
alias Pinchflat.Repo
|
||||
alias Pinchflat.Downloading.MediaDownloadWorker
|
||||
|
||||
setup :verify_on_exit!
|
||||
|
||||
describe "show media" do
|
||||
setup [:create_media_item]
|
||||
|
||||
@@ -49,6 +52,7 @@ defmodule PinchflatWeb.MediaItemControllerTest do
|
||||
describe "delete media" do
|
||||
setup do
|
||||
media_item = media_item_with_attachments()
|
||||
stub(UserScriptRunnerMock, :run, fn _event_type, _data -> :ok end)
|
||||
|
||||
%{media_item: media_item}
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user