Skip to content

Commit

Permalink
ci/goimports: group cilium/ebpf imports after 3rd party imports
Browse files Browse the repository at this point in the history
Signed-off-by: Robin Gögge <r.goegge@isovalent.com>
  • Loading branch information
rgo3 committed Aug 7, 2024
1 parent 3403595 commit 46adb83
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 7 deletions.
6 changes: 6 additions & 0 deletions .golangci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,9 @@ linters:
- typecheck
- unused
- gofmt
linters-settings:
goimports:
# A comma-separated list of prefixes, which, if set, checks import paths
# with the given prefixes are grouped after 3rd-party packages.
# Default: ""
local-prefixes: github.com/cilium/ebpf
3 changes: 2 additions & 1 deletion btf/types_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,10 @@ import (
"reflect"
"testing"

"github.com/cilium/ebpf/internal/testutils"
"github.com/go-quicktest/qt"
"github.com/google/go-cmp/cmp"

"github.com/cilium/ebpf/internal/testutils"
)

func TestSizeof(t *testing.T) {
Expand Down
3 changes: 2 additions & 1 deletion cmd/bpf2go/main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,11 @@ import (
"strings"
"testing"

"github.com/go-quicktest/qt"

"github.com/cilium/ebpf/cmd/bpf2go/gen"
"github.com/cilium/ebpf/cmd/bpf2go/internal"
"github.com/cilium/ebpf/internal/testutils"
"github.com/go-quicktest/qt"
)

const minimalSocketFilter = `__attribute__((section("socket"), used)) int main() { return 0; }`
Expand Down
3 changes: 2 additions & 1 deletion internal/epoll/poller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,9 @@ import (
"testing"
"time"

"github.com/cilium/ebpf/internal/unix"
"github.com/go-quicktest/qt"

"github.com/cilium/ebpf/internal/unix"
)

func TestPoller(t *testing.T) {
Expand Down
5 changes: 3 additions & 2 deletions link/netkit_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,13 @@ import (
"sync/atomic"
"testing"

"github.com/cilium/ebpf"
"github.com/cilium/ebpf/internal/testutils"
"github.com/go-quicktest/qt"
"github.com/jsimonetti/rtnetlink/v2"
"github.com/jsimonetti/rtnetlink/v2/driver"
"golang.org/x/sys/unix"

"github.com/cilium/ebpf"
"github.com/cilium/ebpf/internal/testutils"
)

func TestAttachNetkit(t *testing.T) {
Expand Down
3 changes: 2 additions & 1 deletion link/uprobe_multi_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,10 @@ import (
"os/exec"
"testing"

"github.com/go-quicktest/qt"

"github.com/cilium/ebpf"
"github.com/cilium/ebpf/internal/testutils"
"github.com/go-quicktest/qt"
)

func TestUprobeMulti(t *testing.T) {
Expand Down
3 changes: 2 additions & 1 deletion link/xdp_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@ import (
"math"
"testing"

"github.com/go-quicktest/qt"

"github.com/cilium/ebpf"
"github.com/cilium/ebpf/internal/testutils"
"github.com/go-quicktest/qt"
)

const IfIndexLO = 1
Expand Down

0 comments on commit 46adb83

Please sign in to comment.