mirror of
https://code.forgejo.org/forgejo/runner.git
synced 2025-09-15 18:57:01 +00:00
Update images, fix extrapath (#723)
* fix: typo * fix: remove debug for git references it generates a massive amount of logs * feat: read values from env allows to test act on GHA when it's not a main repo * fix: merge extrapath with PATH * fix(tests): add additional shells for testing * fix(image): update images pin node to major version only, current node version: 12.22.1 replace most images with `node:12-buster-slim` to prevent errors on macOS runner due to DockerHub pull limit replace ocaml image Co-authored-by: Casey Lee <cplee@nektos.com>
This commit is contained in:
parent
bdc0480934
commit
21760b18c2
21 changed files with 103 additions and 50 deletions
|
@ -40,7 +40,7 @@ func TestImageExistsLocally(t *testing.T) {
|
|||
|
||||
// Chose alpine latest because it's so small
|
||||
// maybe we should build an image instead so that tests aren't reliable on dockerhub
|
||||
readerDefault, err := cli.ImagePull(ctx, "alpine:latest", types.ImagePullOptions{
|
||||
readerDefault, err := cli.ImagePull(ctx, "node:12-buster-slim", types.ImagePullOptions{
|
||||
Platform: "linux/amd64",
|
||||
})
|
||||
assert.Nil(t, err)
|
||||
|
@ -48,12 +48,12 @@ func TestImageExistsLocally(t *testing.T) {
|
|||
_, err = ioutil.ReadAll(readerDefault)
|
||||
assert.Nil(t, err)
|
||||
|
||||
imageDefaultArchExists, err := ImageExistsLocally(ctx, "alpine:latest", "linux/amd64")
|
||||
imageDefaultArchExists, err := ImageExistsLocally(ctx, "node:12-buster-slim", "linux/amd64")
|
||||
assert.Nil(t, err)
|
||||
assert.Equal(t, true, imageDefaultArchExists)
|
||||
|
||||
// Validate if another architecture platform can be pulled
|
||||
readerArm64, err := cli.ImagePull(ctx, "alpine:latest", types.ImagePullOptions{
|
||||
readerArm64, err := cli.ImagePull(ctx, "node:12-buster-slim", types.ImagePullOptions{
|
||||
Platform: "linux/arm64",
|
||||
})
|
||||
assert.Nil(t, err)
|
||||
|
@ -61,7 +61,7 @@ func TestImageExistsLocally(t *testing.T) {
|
|||
_, err = ioutil.ReadAll(readerArm64)
|
||||
assert.Nil(t, err)
|
||||
|
||||
imageArm64Exists, err := ImageExistsLocally(ctx, "alpine:latest", "linux/arm64")
|
||||
imageArm64Exists, err := ImageExistsLocally(ctx, "node:12-buster-slim", "linux/arm64")
|
||||
assert.Nil(t, err)
|
||||
assert.Equal(t, true, imageArm64Exists)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue