Skip to content

Commit 3011725

Browse files
committed
try making CI terminate
1 parent 9148611 commit 3011725

File tree

3 files changed

+18
-4
lines changed

3 files changed

+18
-4
lines changed

.github/workflows/tests.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,16 @@ jobs:
5252
actions: write
5353
contents: read
5454
steps:
55+
- name: Install Dependencies
56+
run: |
57+
sudo apt update
58+
sudo apt install -y xvfb mesa-utils mesa-vulkan-drivers dbus
59+
- name: Start Virtual Display
60+
run: |
61+
Xvfb :99 -screen 0 1920x1080x24 &
62+
eval $(dbus-launch)
63+
export DBUS_SESSION_BUS_ADDRESS
64+
export DBUS_SESSION_BUS_PID
5565
- uses: actions/checkout@v4
5666
- uses: julia-actions/setup-julia@v2
5767
with:
@@ -64,7 +74,7 @@ jobs:
6474
uses: GabrielBB/xvfb-action@v1
6575
with:
6676
run: |
67-
julia --project=NetworkDynamicsInspector -e "using Pkg; Pkg.test(coverage=false)"
77+
julia --project=NetworkDynamicsInspector --color=yes -e "using Pkg; Pkg.test(coverage=false)"
6878
# - uses: julia-actions/julia-processcoverage@v1
6979
# - uses: codecov/codecov-action@v4
7080
# with:

NetworkDynamicsInspector/ext/ElectronExt.jl

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,9 @@ end
1616
function NDI.close_display(::NDI.ElectronDisp; strict)
1717
if haswindow()
1818
@info "Close existing Windows"
19-
close.(windows(ELECTRON_APP[]))
19+
while length(windows(ELECTRON_APP[]))>0
20+
close(first(windows(ELECTRON_APP[])))
21+
end
2022
end
2123
if strict
2224
close_application()

NetworkDynamicsInspector/test/runtests.jl

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ end
9595

9696
@testset "track changes in tsplots" begin
9797
sol = get_sol()
98-
inspect(sol; display=BrowserDisp())
98+
inspect(sol; display=ElectronDisp(), restart=true, reset=true)
9999
NDI.APPSTATE[].tsplots[]["ts-1"] = NDI.TimeseriesPlot(selcomp=[EIndex(3), EIndex(2), EIndex(1)], states=[:P])
100100
notify(NDI.APPSTATE[].tsplots) # should update
101101
end
@@ -136,7 +136,9 @@ end
136136

137137
# close all open electron windows
138138
try
139-
close.(Electron.applications())
139+
while !isempty(Electron.applications())
140+
close(first(Electron.applications()))
141+
end
140142
catch
141143
end
142144
end

0 commit comments

Comments
 (0)