Skip to content

Commit

Permalink
Try #10:
Browse files Browse the repository at this point in the history
  • Loading branch information
bors[bot] authored Mar 5, 2021
2 parents a8e5513 + d921d55 commit 47c8e9c
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 5 deletions.
4 changes: 3 additions & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,17 @@ AWSCore = "0.5.2, 0.6"
AWSSDK = "0.2, 0.3, 0.4, 0.5"
AWSTools = "0.3.1, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1"
AutoHashEquals = "0.2.0"
Git_jll = "2.27"
HTTP = "0.8.1"
Memento = "0.7, 0.8, 0.9, 0.10, 0.11, 0.12, 0.13, 1"
Mocking = "0.7"
OrderedCollections = "1.4"
julia = "1"

[extras]
Git_jll = "f8c6e375-362e-5223-8a59-34ff63f689eb"
HTTP = "cd3eb016-35fb-5094-929b-558a96fad6f3"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

[targets]
test = ["HTTP", "Test"]
test = ["Git_jll", "HTTP", "Test"]
19 changes: 15 additions & 4 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ using AWSSDK.CloudWatchLogs: get_log_events
using AWSTools.CloudFormation: stack_output
using AWSTools.EC2: instance_region
using Dates
using Git_jll
using HTTP: HTTP
using Memento
using Memento.TestUtils: @test_log, @test_nolog
Expand All @@ -14,6 +15,19 @@ using Test

Mocking.activate()

function julia_versions()
output = withenv(
"GIT_SSL_CAINFO" => joinpath(dirname(Sys.BINDIR), "share", "julia", "cert.pem"),
"GIT_EXEC_PATH" => joinpath(Git_jll.artifact_dir, "libexec", "git-core"),
) do
git() do git_path
read(`$git_path ls-remote --tags https://github.com/JuliaLang/julia`, String)
end
end
tags = split(replace(output, r".*\/" => ""))
return VersionNumber.(filter!(v -> !endswith(v, "^{}"), tags))
end

# Controls the running of various tests: "local", "batch"
const TESTS = strip.(split(get(ENV, "TESTS", "local"), r"\s*,\s*"))

Expand All @@ -25,10 +39,7 @@ const JOB_TIMEOUT = 900
const LOG_TIMEOUT = 30

const JULIA_BAKED_IMAGE = let
output = read(`git ls-remote --tags https://github.com/JuliaLang/julia`, String)
tags = split(replace(output, r".*\/" => ""))
versions = VersionNumber.(filter(v -> !endswith(v, "^{}"), tags))
latest_version = maximum(versions)
latest_version = maximum(julia_versions())
docker_tag = VERSION > latest_version ? "nightly" : "$VERSION"

"468665244580.dkr.ecr.us-east-1.amazonaws.com/julia-baked:$docker_tag"
Expand Down

0 comments on commit 47c8e9c

Please sign in to comment.