Skip to content

Commit

Permalink
upd
Browse files Browse the repository at this point in the history
  • Loading branch information
pertsevds committed Mar 30, 2024
1 parent 8a236b5 commit ab73272
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
3 changes: 3 additions & 0 deletions lib/dns_srv_cluster/worker.ex
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,9 @@ defmodule DNSSRVCluster.Worker do
%{started: :no} = _state ->
warn_node_not_running_distributed_mode_with_longnames()

%{started: started, name_domain: :shortnames} = _state when started != :no ->
warn_node_not_running_distributed_mode_with_longnames()

# !release? and state.started != :no and state[:name_domain] != :longnames ->
# warn_node_not_running_distributed_mode_with_longnames()

Expand Down
9 changes: 6 additions & 3 deletions test/dns_srv_cluster_app_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,8 @@ defmodule DNSSRVClusterAppTest do
]
)

System.put_env("RELEASE_NAME", "my_app")

Application.stop(:dns_srv_cluster)

res =
Expand All @@ -185,10 +187,11 @@ defmodule DNSSRVClusterAppTest do
:sys.get_state(DNSSRVCluster.get_pid())
end)

assert res =~ "Node not running in distributed mode. Ensure the following exports are set in your rel/env.sh.eex file:"
assert res =~
"Node not running in distributed mode. Ensure the following exports are set in your rel/env.sh.eex file:"

System.delete_env("RELEASE_NAME")

postrun()
end


end

0 comments on commit ab73272

Please sign in to comment.