Remove unreliable test

This commit is contained in:
Jonatan Kłosko 2023-06-09 15:51:01 +02:00
parent c2117e6613
commit 80423adcdf
2 changed files with 4 additions and 18 deletions

View file

@ -18,9 +18,10 @@ defmodule Livebook.Runtime.ErlDist.LoggerGLHandler do
@doc false
def filter_code_server_logs(%{meta: meta} = event, _) do
# When checking if a miscapitalized module, such as Io, is loaded,
# :code_server logs an error message on a case insensitive file
# system "Error loading module 'Elixir.Io'". We want to ignore
# During intellisense we check if certain modules are loaded. If
# the module name is miscapitalized, such as "Io", and we are on
# a case insensitive file system, then :code_serverlogs an error
# message: "Error loading module 'Elixir.Io'". We want to ignore
# such logs
if Process.whereis(:code_server) == meta.pid do

View file

@ -166,21 +166,6 @@ defmodule Livebook.Runtime.ErlDist.RuntimeServerTest do
assert_receive {:runtime_intellisense_response, ^ref, ^request,
%{items: [%{label: "bright/0"}]}}
end
@tag capture_log: true
test "ignores code server error logs when loading mistyped module", %{pid: pid} do
RuntimeServer.evaluate_code(pid, :elixir, "", {:c1, :e1}, [])
assert_receive {:runtime_evaluation_response, :e1, _, %{evaluation_time_ms: _time_ms}}
request = {:completion, "Io."}
ref = RuntimeServer.handle_intellisense(pid, self(), request, [])
assert_receive {:runtime_intellisense_response, ^ref, ^request, %{items: []}}
# Checking if the module is loaded results in "Error loading module 'Elixir.Io'"
# error log, which should be ignored
refute_receive {:runtime_evaluation_output, :e1, {:stdout, _log_message}}
end
end
describe "handle_intellisense/5 given details request" do