Skip to content

Commit

Permalink
Add base-case test for which_children/1
Browse files Browse the repository at this point in the history
  • Loading branch information
derekkraan committed Feb 12, 2024
1 parent 3a8dd44 commit c71fc75
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions test/dynamic_supervisor_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -285,6 +285,10 @@ defmodule DynamicSupervisorTest do
end

describe ".which_children/1" do
test "is empty", context do
assert [] = Horde.DynamicSupervisor.which_children(context.horde_1)
end

test "collects results from all horde nodes", context do
Horde.DynamicSupervisor.start_child(context.horde_1, %{context.task_def | id: :proc_1})
Horde.DynamicSupervisor.start_child(context.horde_1, %{context.task_def | id: :proc_2})
Expand Down

0 comments on commit c71fc75

Please sign in to comment.