mirror of
https://github.com/hanzo-git/runner.git
synced 2026-10-30 19:33:27 +00:00
Native runner: module github.com/hanzo-git/runner, wire proto github.com/hanzo-git/actions-proto-go, command git-runner, GIT_* env, git expr context, git_* task-context keys, ghcr.io/hanzoai/runner-ubuntu job images. Derived work — upstream attribution + MIT terms in NOTICE/LICENSE. Co-authored-by: Hanzo Dev <[email protected]>
21 lines
479 B
Go
21 lines
479 B
Go
// Copyright 2026 The Git Authors. All rights reserved.
|
|
// SPDX-License-Identifier: MIT
|
|
|
|
package envcheck
|
|
|
|
import (
|
|
"context"
|
|
"testing"
|
|
|
|
"github.com/stretchr/testify/require"
|
|
)
|
|
|
|
func TestCheckIfDockerRunningReturnsPingError(t *testing.T) {
|
|
ctx, cancel := context.WithCancel(context.Background())
|
|
cancel()
|
|
|
|
err := CheckIfDockerRunning(ctx, "unix:///definitely/missing/docker.sock")
|
|
require.Error(t, err)
|
|
require.Contains(t, err.Error(), "cannot ping the docker daemon")
|
|
}
|