From 0472b96bfe9feaa1fc80868a766887f4118f79e9 Mon Sep 17 00:00:00 2001 From: Tony Kelman Date: Fri, 15 Jan 2016 14:14:13 -0800 Subject: [PATCH] Add test for and close #12671, starting from non directory use mktempdir instead of tempname because of #9053 Cygwin lets you do this but win32 doesn't Only run test for 12671 if llvm is new enough --- test/cmdlineargs.jl | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/test/cmdlineargs.jl b/test/cmdlineargs.jl index 98615fa24ddcd..b0c78d2b9c821 100644 --- a/test/cmdlineargs.jl +++ b/test/cmdlineargs.jl @@ -239,4 +239,13 @@ let exename = `$(joinpath(JULIA_HOME, Base.julia_exename())) --precompiled=yes` @test readchomp(`$exename --compilecache=yes -E "Bool(Base.JLOptions().use_compilecache)"`) == "true" @test readchomp(`$exename --compilecache=no -E "Bool(Base.JLOptions().use_compilecache)"`) == "false" @test !success(`$exename --compilecache=foo -e "exit(0)"`) + + # issue #12671, starting from a non-directory + @unix_only if VersionNumber(Base.libllvm_version) > v"3.3" + testdir = mktempdir() + cd(testdir) do + rm(testdir) + @test success(`$exename -e "exit(0)"`) + end + end end