mirror of
https://github.com/strukturag/nextcloud-spreed-signaling
synced 2026-03-14 14:35:44 +01:00
Merge pull request #1196 from strukturag/golang-1.26
CI: Test with Golang 1.26
This commit is contained in:
commit
083858294a
7 changed files with 28 additions and 9 deletions
4
.github/workflows/lint.yml
vendored
4
.github/workflows/lint.yml
vendored
|
|
@ -49,7 +49,7 @@ jobs:
|
|||
- uses: actions/checkout@v6
|
||||
- uses: actions/setup-go@v6
|
||||
with:
|
||||
go-version: "1.25"
|
||||
go-version: "1.26"
|
||||
|
||||
- name: moderize
|
||||
run: |
|
||||
|
|
@ -63,7 +63,7 @@ jobs:
|
|||
- uses: actions/checkout@v6
|
||||
- uses: actions/setup-go@v6
|
||||
with:
|
||||
go-version: "1.25"
|
||||
go-version: "1.26"
|
||||
check-latest: true
|
||||
|
||||
- name: checklocks
|
||||
|
|
|
|||
3
.github/workflows/tarball.yml
vendored
3
.github/workflows/tarball.yml
vendored
|
|
@ -26,6 +26,7 @@ jobs:
|
|||
go-version:
|
||||
- "1.24"
|
||||
- "1.25"
|
||||
- "1.26"
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
|
|
@ -50,6 +51,7 @@ jobs:
|
|||
go-version:
|
||||
- "1.24"
|
||||
- "1.25"
|
||||
- "1.26"
|
||||
runs-on: ubuntu-latest
|
||||
needs: [create]
|
||||
steps:
|
||||
|
|
@ -95,6 +97,7 @@ jobs:
|
|||
go-version:
|
||||
- "1.24"
|
||||
- "1.25"
|
||||
- "1.26"
|
||||
runs-on: ubuntu-latest
|
||||
needs: [create]
|
||||
steps:
|
||||
|
|
|
|||
4
.github/workflows/test.yml
vendored
4
.github/workflows/test.yml
vendored
|
|
@ -28,6 +28,7 @@ jobs:
|
|||
go-version:
|
||||
- "1.24"
|
||||
- "1.25"
|
||||
- "1.26"
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
|
|
@ -51,6 +52,7 @@ jobs:
|
|||
go-version:
|
||||
- "1.24"
|
||||
- "1.25"
|
||||
- "1.26"
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
|
|
@ -71,6 +73,7 @@ jobs:
|
|||
go-version:
|
||||
- "1.24"
|
||||
- "1.25"
|
||||
- "1.26"
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
|
|
@ -91,6 +94,7 @@ jobs:
|
|||
go-version:
|
||||
- "1.24"
|
||||
- "1.25"
|
||||
- "1.26"
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
|
|
|
|||
20
Makefile
20
Makefile
|
|
@ -6,7 +6,7 @@ GODIR := $(shell dirname "$(GO)")
|
|||
GOFMT := "$(GODIR)/gofmt"
|
||||
GOOS ?= linux
|
||||
GOARCH ?= amd64
|
||||
GOVERSION := $(shell "$(GO)" env GOVERSION | sed "s|go||" )
|
||||
GOVERSION := $(shell "$(GO)" env GOVERSION | sed -E 's|go([0-9]+\.[0-9]+)\..*|\1|')
|
||||
TMPDIR := $(CURDIR)/tmp
|
||||
BINDIR := $(CURDIR)/bin
|
||||
VENDORDIR := "$(CURDIR)/vendor"
|
||||
|
|
@ -77,6 +77,12 @@ else
|
|||
GOPATHBIN := $(GOPATH)/bin/$(GOOS)_$(GOARCH)
|
||||
endif
|
||||
|
||||
ifeq ($(GOVERSION), 1.24)
|
||||
GOEXPERIMENT := synctest
|
||||
else
|
||||
GOEXPERIMENT :=
|
||||
endif
|
||||
|
||||
hook:
|
||||
[ ! -d "$(CURDIR)/.git/hooks" ] || ln -sf "$(CURDIR)/scripts/pre-commit.hook" "$(CURDIR)/.git/hooks/pre-commit"
|
||||
|
||||
|
|
@ -110,24 +116,24 @@ fmt: hook | $(PROTO_GO_FILES)
|
|||
$(GOFMT) -s -w *.go cmd/client cmd/proxy cmd/server
|
||||
|
||||
vet:
|
||||
GOEXPERIMENT=synctest $(GO) vet ./...
|
||||
GOEXPERIMENT=$(GOEXPERIMENT) $(GO) vet ./...
|
||||
|
||||
test: vet
|
||||
GOEXPERIMENT=synctest $(GO) test -timeout $(TIMEOUT) $(TESTARGS) ./...
|
||||
GOEXPERIMENT=$(GOEXPERIMENT) $(GO) test -timeout $(TIMEOUT) $(TESTARGS) ./...
|
||||
|
||||
benchmark:
|
||||
GOEXPERIMENT=synctest $(GO) test -bench=$(BENCHMARK) -benchmem -run=^$$ -timeout $(TIMEOUT) $(TESTARGS) ./...
|
||||
GOEXPERIMENT=$(GOEXPERIMENT) $(GO) test -bench=$(BENCHMARK) -benchmem -run=^$$ -timeout $(TIMEOUT) $(TESTARGS) ./...
|
||||
|
||||
checklocks: $(GOPATHBIN)/checklocks
|
||||
GOEXPERIMENT=synctest go vet -vettool=$(GOPATHBIN)/checklocks ./...
|
||||
GOEXPERIMENT=$(GOEXPERIMENT) go vet -vettool=$(GOPATHBIN)/checklocks ./...
|
||||
|
||||
cover: vet
|
||||
rm -f cover.out && \
|
||||
GOEXPERIMENT=synctest $(GO) test -timeout $(TIMEOUT) -coverprofile cover.out ./...
|
||||
GOEXPERIMENT=$(GOEXPERIMENT) $(GO) test -timeout $(TIMEOUT) -coverprofile cover.out ./...
|
||||
|
||||
coverhtml: vet
|
||||
rm -f cover.out && \
|
||||
GOEXPERIMENT=synctest $(GO) test -timeout $(TIMEOUT) -coverprofile cover.out ./... && \
|
||||
GOEXPERIMENT=$(GOEXPERIMENT) $(GO) test -timeout $(TIMEOUT) -coverprofile cover.out ./... && \
|
||||
sed -i "/_easyjson/d" cover.out && \
|
||||
sed -i "/\.pb\.go/d" cover.out && \
|
||||
$(GO) tool cover -html=cover.out -o coverage.html
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
//go:build go1.25
|
||||
|
||||
/**
|
||||
* Standalone signaling server for the Nextcloud Spreed app.
|
||||
* Copyright (C) 2021 struktur AG
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
//go:build go1.25
|
||||
|
||||
/**
|
||||
* Standalone signaling server for the Nextcloud Spreed app.
|
||||
* Copyright (C) 2021 struktur AG
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
//go:build go1.25
|
||||
|
||||
/**
|
||||
* Standalone signaling server for the Nextcloud Spreed app.
|
||||
* Copyright (C) 2022 struktur AG
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue