File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed
Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -286,7 +286,7 @@ defmodule Mix.Tasks.Escript.Build do
286286 quote do
287287 erl_version = :erlang . system_info ( :otp_release )
288288 case :string . to_integer ( erl_version ) do
289- { num , _ } when is_integer ( num ) and num >= 17 -> nil
289+ { num , _ } when num >= 17 -> nil
290290 _ ->
291291 io_error [ "Incompatible Erlang/OTP release: " , erl_version ,
292292 ".\n This escript requires at least Erlang/OTP 17.0.\n " ]
Original file line number Diff line number Diff line change @@ -83,6 +83,7 @@ defmodule MixTest.Case do
8383 def in_fixture ( which , tmp , function ) do
8484 src = fixture_path ( which )
8585 dest = tmp_path ( tmp )
86+ flag = String . to_char_list ( tmp_path )
8687
8788 File . rm_rf! ( dest )
8889 File . mkdir_p! ( dest )
@@ -95,7 +96,12 @@ defmodule MixTest.Case do
9596 File . cd! dest , function
9697 after
9798 :code . set_path ( get_path )
98- for { mod , :in_memory } <- :code . all_loaded -- previous , do: purge [ mod ]
99+
100+ for { mod , file } <- :code . all_loaded -- previous ,
101+ file == :in_memory or
102+ ( is_list ( file ) and :lists . prefix ( flag , file ) ) do
103+ purge [ mod ]
104+ end
99105 end
100106 end
101107
You can’t perform that action at this time.
0 commit comments