Skip to content

Commit

Permalink
avoid writing into package depot dir
Browse files Browse the repository at this point in the history
  • Loading branch information
tanmaykm committed Feb 22, 2024
1 parent 82930e5 commit 668dfee
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions test/runtests_routeguide.jl
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,14 @@ end

function test_generate()
@testset "codegen" begin
dir = joinpath(@__DIR__, "RouteguideClients")
gRPCClient.generate(joinpath(dir, "route_guide.proto"); outdir=dir)
@test isfile(joinpath(dir, "route_guide_pb.jl"))
@test isfile(joinpath(dir, "routeguide.jl"))
@test isfile(joinpath(dir, "RouteguideClients.jl"))
# dir = joinpath(@__DIR__, "RouteguideClients")
# generate into tempdir to avoid writing inside depot folder
tempdir() do dir
gRPCClient.generate(joinpath(dir, "route_guide.proto"); outdir=dir)
@test isfile(joinpath(dir, "route_guide_pb.jl"))
@test isfile(joinpath(dir, "routeguide.jl"))
@test isfile(joinpath(dir, "RouteguideClients.jl"))
end
end
end

Expand Down

0 comments on commit 668dfee

Please sign in to comment.