File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -36,10 +36,10 @@ defmodule ElixirLS.Utils.Launch do
3636
3737 def get_versions do
3838 % {
39- current_elixir_version: inspect ( System . build_info ( ) [ :build ] ) ,
40- current_otp_version: inspect ( System . otp_release ( ) ) ,
41- compile_elixir_version: inspect ( @ compiled_elixir_version ) ,
42- compile_otp_version: inspect ( @ compiled_otp_version )
39+ current_elixir_version: to_string ( System . build_info ( ) [ :build ] ) ,
40+ current_otp_version: to_string ( System . otp_release ( ) ) ,
41+ compile_elixir_version: to_string ( @ compiled_elixir_version ) ,
42+ compile_otp_version: to_string ( @ compiled_otp_version )
4343 }
4444 end
4545
Original file line number Diff line number Diff line change 1+ defmodule ElixirLS.Utils.LaunchTest do
2+ use ExUnit.Case , async: true
3+
4+ test "get_versions returns plain strings" do
5+ versions = ElixirLS.Utils.Launch . get_versions ( )
6+
7+ assert is_binary ( versions . current_elixir_version )
8+ assert is_binary ( versions . current_otp_version )
9+ assert is_binary ( versions . compile_elixir_version )
10+ assert is_binary ( versions . compile_otp_version )
11+
12+ for value <- Map . values ( versions ) do
13+ refute String . starts_with? ( value , "\" " )
14+ refute String . ends_with? ( value , "\" " )
15+ end
16+ end
17+ end
You can’t perform that action at this time.
0 commit comments