Skip to content

Commit 2e355c2

Browse files
authored
Use Tar.jl to create tarball to use for Wizard tests (#1025)
1 parent 2428204 commit 2e355c2

File tree

4 files changed

+13
-10
lines changed

4 files changed

+13
-10
lines changed

Manifest.toml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ uuid = "2a0f44e3-6c83-55bd-87e4-b1978d98bd5f"
2828

2929
[[BinaryBuilderBase]]
3030
deps = ["CodecZlib", "Downloads", "InteractiveUtils", "JSON", "LibGit2", "Libdl", "Logging", "OutputCollectors", "Pkg", "Random", "SHA", "Scratch", "SimpleBufferStream", "TOML", "Tar", "UUIDs", "p7zip_jll", "pigz_jll"]
31-
git-tree-sha1 = "557b497af843c3f48fe4678c4b47b13db81805aa"
31+
git-tree-sha1 = "87236ea2e2cf83b4a5bbeb29bc76c94f4a3252d4"
3232
repo-rev = "master"
3333
repo-url = "https://github.com/JuliaPackaging/BinaryBuilderBase.jl.git"
3434
uuid = "7f725544-6523-48cd-82d1-3fa08ff4056e"
@@ -122,9 +122,9 @@ version = "1.0.0"
122122

123123
[[JLD2]]
124124
deps = ["CodecZlib", "DataStructures", "MacroTools", "Mmap", "Pkg", "Printf", "Requires", "UUIDs"]
125-
git-tree-sha1 = "e8c4d588007dc02a1b23442ef3d14a8d7146df97"
125+
git-tree-sha1 = "b8343a7f96591404ade118b3a7014e1a52062465"
126126
uuid = "033835bb-8acc-5ee8-8aae-3f567f8a3819"
127-
version = "0.4.1"
127+
version = "0.4.2"
128128

129129
[[JLLWrappers]]
130130
git-tree-sha1 = "a431f5f2ca3f4feef3bd7a5e94b8b8d4f2f647a0"
@@ -234,9 +234,9 @@ version = "0.1.0"
234234

235235
[[Parsers]]
236236
deps = ["Dates"]
237-
git-tree-sha1 = "50c9a9ed8c714945e01cd53a21007ed3865ed714"
237+
git-tree-sha1 = "223a825cccef2228f3fdbf2ecc7ca93363059073"
238238
uuid = "69de0a69-1ddd-5017-9359-2bf0b02dc9f0"
239-
version = "1.0.15"
239+
version = "1.0.16"
240240

241241
[[Pidfile]]
242242
deps = ["FileWatching", "Test"]
@@ -245,7 +245,7 @@ uuid = "fa939f87-e72e-5be4-a000-7fc836dbe307"
245245
version = "1.2.0"
246246

247247
[[Pkg]]
248-
deps = ["Artifacts", "Dates", "Downloads", "LibGit2", "Libdl", "Logging", "Markdown", "Printf", "REPL", "Random", "SHA", "Serialization", "TOML", "Tar", "UUIDs"]
248+
deps = ["Artifacts", "Dates", "Downloads", "LibGit2", "Libdl", "Logging", "Markdown", "Printf", "REPL", "Random", "SHA", "Serialization", "TOML", "Tar", "UUIDs", "p7zip_jll"]
249249
uuid = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f"
250250

251251
[[PkgLicenses]]

Project.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,9 @@ julia = "1.6"
5252

5353
[extras]
5454
JLLWrappers = "692b3bcd-3c85-4b1f-b108-f13ce0eb3210"
55+
Tar = "a4e569a6-e804-4fa4-b0f3-eef7a1d5b13e"
5556
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
5657
VT100 = "7774df62-37c0-5c21-b34d-f6d7f98f54bc"
5758

5859
[targets]
59-
test = ["JLLWrappers", "Test", "VT100"]
60+
test = ["JLLWrappers", "Tar", "Test", "VT100"]

azure-pipelines.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ variables:
1313
JULIA: unbuffer julia --project=$(Build.SourcesDirectory) --color=yes
1414
BINARYBUILDER_AUTOMATIC_APPLE: true
1515
BINARYBUILDER_USE_CCACHE: true
16+
CI: true
1617

1718
jobs:
1819
- job: Info

test/wizard.jl

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
using BinaryBuilder, BinaryBuilder.BinaryBuilderBase, BinaryBuilder.Wizard
2-
using GitHub, Test, VT100, Sockets, HTTP, SHA
2+
using GitHub, Test, VT100, Sockets, HTTP, SHA, Tar
33
import Pkg: PackageSpec
44

55
import BinaryBuilder.BinaryBuilderBase: available_gcc_builds, available_llvm_builds, getversion
@@ -47,8 +47,9 @@ end
4747

4848
# Test the download stage
4949
r = HTTP.Router()
50-
build_tests_dir = joinpath(@__DIR__, "build_tests")
51-
libfoo_tarball_data = read(`tar czf - -C $(build_tests_dir) libfoo`)
50+
io = IOBuffer()
51+
Tar.create(joinpath(build_tests_dir, "libfoo"), pipeline(`gzip -9`, io))
52+
libfoo_tarball_data = take!(io)
5253
libfoo_tarball_hash = bytes2hex(sha256(libfoo_tarball_data))
5354
function serve_tgz(req)
5455
HTTP.Response(200, libfoo_tarball_data)

0 commit comments

Comments
 (0)