Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gh: update workflows and add test for macos arm64 #21

Merged
merged 1 commit into from
Jul 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
fetch-depth: 1
- name: Set up Go
uses: actions/setup-go@v5
with:
Expand All @@ -25,4 +25,4 @@ jobs:
- name: Test Race
run: go test -race ./...
- name: Test Builds
run: make test_build
run: make test_build --jobs=4
6 changes: 3 additions & 3 deletions .github/workflows/macos.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Test fastwalk on macOS
name: Test fastwalk on macOS amd64

on:
push:
Expand All @@ -8,14 +8,14 @@ on:

jobs:
build:
runs-on: macos-latest
runs-on: macos-13
strategy:
matrix:
go: [1.21, 1.22]
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
fetch-depth: 1
- name: Set up Go
uses: actions/setup-go@v5
with:
Expand Down
26 changes: 26 additions & 0 deletions .github/workflows/macos_arm64.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Test fastwalk on macOS arm64

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
build:
runs-on: macos-latest
strategy:
matrix:
go: [1.21, 1.22]
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 1
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go }}
- name: Test
run: go test ./...
- name: Test Race
run: go test -race ./...
4 changes: 1 addition & 3 deletions .github/workflows/windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,10 @@ jobs:
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
fetch-depth: 1
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go }}
- name: Test
run: go test ./...
- name: Test Race
run: go test -race ./...
3 changes: 3 additions & 0 deletions fastwalk_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -321,6 +321,9 @@ func maxPathLength(t testing.TB) (root string, pathMax int) {
// Test that we can handle PATH_MAX. This is mostly for the Unix tests
// where we pass a buffer to ReadDirect (often getdents64(2)).
func TestFastWalk_LongPath(t *testing.T) {
if runtime.GOOS == "windows" {
t.Skip("test not needed on Windows")
}
root, pathMax := maxPathLength(t)
t.Log("PATH_MAX:", pathMax)

Expand Down
Loading