Skip to content
代码片段 群组 项目
提交 757dbb52 编辑于 作者: Javiera Tapia's avatar Javiera Tapia 提交者: Igor Drozdov
浏览文件

Move root *.go files to gitlab-workhorse directory

上级 079e19f5
No related branches found
No related tags found
无相关合并请求
显示
10 个添加19 个删除
......@@ -64,22 +64,13 @@ WITHOUT_BUILD_ID ?=
.PHONY: all
all: clean-build $(EXE_ALL)
.PHONY: gitlab-resize-image gitlab-zip-cat gitlab-zip-metadata
gitlab-resize-image gitlab-zip-cat gitlab-zip-metadata:
.PHONY: gitlab-resize-image gitlab-zip-cat gitlab-zip-metadata gitlab-workhorse
gitlab-resize-image gitlab-zip-cat gitlab-zip-metadata gitlab-workhorse:
$(call message,Building $@)
go build -ldflags "$(GO_BUILD_GENERIC_LDFLAGS)" -tags "$(BUILD_TAGS)" -o $(BUILD_DIR)/$@ $(PKG)/cmd/$@
ifndef WITHOUT_BUILD_ID
go build -ldflags "$(GO_BUILD_GENERIC_LDFLAGS) -B 0x$$(_support/make-gnu-build-id.sh $(BUILD_DIR)/$@)" -tags "$(BUILD_TAGS)" -o $(BUILD_DIR)/$@ $(PKG)/cmd/$@
endif
.PHONY: gitlab-workhorse
gitlab-workhorse:
$(call message,Building $@)
go build -ldflags "$(GO_BUILD_GENERIC_LDFLAGS)" -tags "$(BUILD_TAGS)" -o $(BUILD_DIR)/$@ $(PKG)
ifndef WITHOUT_BUILD_ID
go build -ldflags "$(GO_BUILD_GENERIC_LDFLAGS) -B 0x$$(_support/make-gnu-build-id.sh $(BUILD_DIR)/$@)" -tags "$(BUILD_TAGS)" -o $(BUILD_DIR)/$@ $(PKG)
endif
.PHONY: install
install: $(EXE_ALL)
$(call message,$@)
......
文件已移动
文件已移动
......@@ -14,7 +14,7 @@ import (
)
func TestNewListener(t *testing.T) {
const unixSocket = "testdata/sock"
const unixSocket = "../../testdata/sock"
require.NoError(t, os.RemoveAll(unixSocket))
......@@ -61,8 +61,8 @@ func pingClient(t *testing.T, c net.Conn) {
func TestNewListener_TLS(t *testing.T) {
const (
certFile = "testdata/localhost.crt"
keyFile = "testdata/localhost.key"
certFile = "../../testdata/localhost.crt"
keyFile = "../../testdata/localhost.key"
)
cfg := config.ListenerConfig{Addr: "127.0.0.1:0",
......
文件已移动
文件已移动
......@@ -35,9 +35,9 @@ import (
"gitlab.com/gitlab-org/gitlab/workhorse/internal/upstream"
)
const testRepoRoot = "testdata/repo"
const testDocumentRoot = "testdata/public"
const testAltDocumentRoot = "testdata/alt-public"
const testRepoRoot = "../../testdata/repo"
const testDocumentRoot = "../../testdata/public"
const testAltDocumentRoot = "../../testdata/alt-public"
var absDocumentRoot string
......@@ -405,7 +405,7 @@ func doSendDataRequest(t *testing.T, path string, command, literalJSON string) (
func TestArtifactsGetSingleFile(t *testing.T) {
// We manually created this zip file in the gitlab-workhorse Git repository
archivePath := `testdata/artifacts-archive.zip`
archivePath := `../../testdata/artifacts-archive.zip`
fileName := "myfile"
fileContents := "MY FILE"
resourcePath := `/namespace/project/builds/123/artifacts/file/` + fileName
......@@ -421,7 +421,7 @@ func TestArtifactsGetSingleFile(t *testing.T) {
}
func TestImageResizing(t *testing.T) {
imageLocation := `testdata/image.png`
imageLocation := `../../testdata/image.png`
requestedWidth := 40
imageFormat := "image/png"
jsonParams := fmt.Sprintf(`{"Location":"%s","Width":%d, "ContentType":"%s"}`, imageLocation, requestedWidth, imageFormat)
......
文件已移动
文件已移动
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册