diff --git a/Project.toml b/Project.toml index d9e3618..144f706 100644 --- a/Project.toml +++ b/Project.toml @@ -1,7 +1,7 @@ name = "PkgAuthentication" uuid = "4722fa14-9d28-45f9-a1e2-a38605bd88f0" authors = ["Sebastian Pfitzner", "contributors"] -version = "2.1.0" +version = "2.1.1" [deps] Downloads = "f43a241f-c20a-4ad4-852c-f6b1247861c6" diff --git a/src/helpers.jl b/src/helpers.jl index 6a9eda9..c03ecc2 100644 --- a/src/helpers.jl +++ b/src/helpers.jl @@ -6,7 +6,7 @@ else # https://github.com/JuliaLang/julia/pull/57069 function detectwsl() # We use the same approach as canonical/snapd do to detect WSL - islinux() && ( + Sys.islinux() && ( isfile("/proc/sys/fs/binfmt_misc/WSLInterop") || isdir("/run/WSL") ) diff --git a/test/utilities_test.jl b/test/utilities_test.jl index c9b13ec..bfcab0a 100644 --- a/test/utilities_test.jl +++ b/test/utilities_test.jl @@ -8,4 +8,6 @@ @test PkgAuthentication.assert_dict_keys(Dict("bar" => 0), "foo", "bar"; msg="") === nothing @test_throws ErrorException PkgAuthentication.assert_dict_keys(Dict(), "foo", "bar"; msg="") @test_throws ErrorException PkgAuthentication.assert_dict_keys(Dict("baz" => 0), "foo", "bar"; msg="") + + @test PkgAuthentication.detectwsl() isa Bool end