Skip to content

Commit

Permalink
fix: use annotations on provider start
Browse files Browse the repository at this point in the history
Signed-off-by: Brooks Townsend <[email protected]>

make tests accurate
  • Loading branch information
brooksmtownsend committed Oct 25, 2023
1 parent 8f00103 commit c18d333
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
3 changes: 1 addition & 2 deletions lib/lattice_observer/observed/lattice.ex
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,6 @@ defmodule LatticeObserver.Observed.Lattice do
}
) do
annotations = Map.get(d, "annotations", %{})
spec = Map.get(annotations, @annotation_app_spec, "")
claims = Map.get(d, "claims", %{})

l =
Expand All @@ -309,7 +308,7 @@ defmodule LatticeObserver.Observed.Lattice do
link_name,
contract_id,
instance_id,
spec,
annotations,
stamp,
claims
)
Expand Down
2 changes: 1 addition & 1 deletion mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ defmodule LatticeObserver.MixProject do
def project do
[
app: :lattice_observer,
version: "0.4.2",
version: "0.4.3",
elixir: "~> 1.12",
elixirc_paths: compiler_paths(Mix.env()),
start_permanent: Mix.env() == :prod,
Expand Down
4 changes: 2 additions & 2 deletions test/support/cloud_events.ex
Original file line number Diff line number Diff line change
Expand Up @@ -74,13 +74,13 @@ defmodule TestSupport.CloudEvents do
|> Cloudevents.from_map!()
end

def provider_started(pk, contract_id, link_name, instance_id, spec, host) do
def provider_started(pk, contract_id, link_name, instance_id, annotations, host) do
%{
"public_key" => pk,
"instance_id" => instance_id,
"link_name" => link_name,
"contract_id" => contract_id,
"annotations" => %{@appspec => spec},
"annotations" => annotations,
"claims" => %{
"name" => "test provider",
"version" => "1.0",
Expand Down

0 comments on commit c18d333

Please sign in to comment.