Skip to content

Commit

Permalink
closes #1116
Browse files Browse the repository at this point in the history
  • Loading branch information
taylordowns2000 committed Sep 14, 2023
1 parent 5716d9d commit 1e290d6
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion lib/lightning_web/live/run_live/components.ex
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,7 @@ defmodule LightningWeb.RunLive.Components do
"#{DateTime.diff(run.finished_at, run.started_at, :millisecond)} ms"

run.started_at ->
"#{DateTime.diff(DateTime.utc_now(), run.started_at, :millisecond)} ms"
"..."

true ->
"Not started."
Expand Down
6 changes: 4 additions & 2 deletions test/lightning_web/live/run_live/components_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -248,8 +248,10 @@ defmodule LightningWeb.RunLive.ComponentsTest do

assert html
|> Floki.find("div#ran-for-#{run.id} > div:nth-child(2)")
|> Floki.text() =~
~r/25\d\d\d ms/
|> Floki.text() =~ "..."

# TODO: add a timer that counts up from run.started_at
# ~r/25\d\d\d ms/

assert html
|> Floki.find("div#exit-code-#{run.id} > div:nth-child(2)")
Expand Down
6 changes: 4 additions & 2 deletions test/lightning_web/live/work_order_live_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -1212,8 +1212,10 @@ defmodule LightningWeb.RunWorkOrderTest do

assert html
|> Floki.find("div#ran-for-#{run.id} > div:nth-child(2)")
|> Floki.text() =~
~r/25\d\d\d ms/
|> Floki.text() =~ "..."

# TODO: add a timer that counts up from run.started_at
# ~r/25\d\d\d ms/

assert html
|> Floki.find("div#exit-code-#{run.id} > div:nth-child(2)")
Expand Down

0 comments on commit 1e290d6

Please sign in to comment.