Skip to content

Commit

Permalink
Run JuliaInterface tests from runtests.jl via shell script (#1014)
Browse files Browse the repository at this point in the history
  • Loading branch information
lgoettgens authored Jul 2, 2024
1 parent 0cc113d commit ceda58f
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/setup.jl
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ function create_gap_sh(dstdir::String)
## Create Project.toml & Manifest.toml for use by gap.sh
##
@info "Generating custom Julia project ..."
run(pipeline(`$(Base.julia_cmd()) --startup-file=no --project=$(dstdir) -e "using Pkg; Pkg.develop(PackageSpec(path=\"$(gaproot_gapjl)\"))"`))
run(`$(Base.julia_cmd()) --startup-file=no --project=$(dstdir) -e "using Pkg; Pkg.develop(PackageSpec(path=\"$(gaproot_gapjl)\"))"`)

##
## Create custom gap.sh
Expand Down
2 changes: 2 additions & 0 deletions test/Project.toml
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
[deps]
Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595"
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
Pkg = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f"
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

[compat]
Aqua = "0.8.2"
Documenter = "^0.27.0"
Pkg = "1.6"
Random = "1.6"
Test = "1.6"
9 changes: 9 additions & 0 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,12 @@ end
@testset "manual examples" begin
include("doctest.jl")
end

@testset "JuliaInterface tests" begin
mktempdir() do tmpdir
GAP.create_gap_sh(tmpdir)
cmd = Cmd(`$(joinpath("etc", "ci_test.sh"))`; dir=dirname(dirname(pathof(GAP))))
cmd = addenv(cmd, "GAP" => "$(joinpath(tmpdir, "gap.sh")) -A --quitonbreak --norepl")
@test success(pipeline(cmd; stdout, stderr))
end
end

0 comments on commit ceda58f

Please sign in to comment.