fix(test): fix flaky test node setup

This commit is contained in:
Thales Macedo Garitezi 2022-04-19 15:36:47 -03:00
parent ac7a13f9f2
commit ec1ff14759
No known key found for this signature in database
GPG Key ID: DD279F8152A9B6DD
1 changed files with 8 additions and 3 deletions

View File

@ -662,7 +662,12 @@ host() ->
Host.
ebin_path() ->
string:join(["-pa" | lists:filter(fun is_lib/1, code:get_path())], " ").
string:join(["-pa" | paths()], " ").
is_lib(Path) ->
string:prefix(Path, code:lib_dir()) =:= nomatch.
paths() ->
[
Path
|| Path <- code:get_path(),
string:prefix(Path, code:lib_dir()) =:= nomatch,
string:str(Path, "_build/default/plugins") =:= 0
].