Skip to content

Commit

Permalink
feat: pfm ibc v10 missing e2e (#235)
Browse files Browse the repository at this point in the history
Co-authored-by: Gjermund Garaba <gjermund@garaba.net>
  • Loading branch information
vladjdk and gjermundgaraba authored Feb 24, 2025
1 parent 515bdca commit 625908c
Show file tree
Hide file tree
Showing 32 changed files with 1,325 additions and 1,341 deletions.
4 changes: 2 additions & 2 deletions middleware/packet-forward-middleware/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# docker build . -t pfm:local
# docker run --rm -it pfm:local q ibc-router

FROM golang:1.21-alpine3.18 AS builder
FROM golang:1.23-alpine3.21 AS builder

RUN set -eux; apk add --no-cache git libusb-dev linux-headers gcc musl-dev make;

Expand All @@ -22,7 +22,7 @@ COPY . .

RUN make build

FROM alpine:3.18
FROM alpine:3.21

COPY --from=builder /go/build/simd /bin/simd

Expand Down
14 changes: 7 additions & 7 deletions middleware/packet-forward-middleware/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -146,8 +146,8 @@ mocks: $(MOCKS_DIR)
mockgen -package=mock -destination=./test/mock/transfer_keeper.go $(GOMOD)/packetforward/types TransferKeeper
mockgen -package=mock -destination=./test/mock/bank_keeper.go $(GOMOD)/packetforward/types BankKeeper
mockgen -package=mock -destination=./test/mock/channel_keeper.go $(GOMOD)/packetforward/types ChannelKeeper
mockgen -package=mock -destination=./test/mock/ics4_wrapper.go github.com/cosmos/ibc-go/v8/modules/core/05-port/types ICS4Wrapper
mockgen -package=mock -destination=./test/mock/ibc_module.go github.com/cosmos/ibc-go/v8/modules/core/05-port/types IBCModule
mockgen -package=mock -destination=./test/mock/ics4_wrapper.go github.com/cosmos/ibc-go/v10/modules/core/05-port/types ICS4Wrapper
mockgen -package=mock -destination=./test/mock/ibc_module.go github.com/cosmos/ibc-go/v10/modules/core/05-port/types IBCModule

.PHONY: mocks

Expand Down Expand Up @@ -218,19 +218,19 @@ local-image:
docker build . -t pfm:local

ictest-forward:
cd e2e && go test -race -v -timeout 15m -run TestPacketForwardMiddleware .
cd e2e && go test -race -v -timeout 30m -run TestPacketForwardMiddleware .

ictest-timeout:
cd e2e && go test -race -v -timeout 15m -run TestTimeoutOnForward .
cd e2e && go test -race -v -timeout 30m -run TestTimeoutOnForward .

ictest-storage-leak:
cd e2e && go test -race -v -timeout 15m -run TestStorageLeak .
cd e2e && go test -race -v -timeout 30m -run TestStorageLeak .

ictest-upgrade:
cd e2e && go test -race -v -timeout 15m -run TestPFMUpgrade .
cd e2e && go test -race -v -timeout 30m -run TestPFMUpgrade .

ictest-nonrefundable:
cd e2e && go test -race -v -timeout 15m -run TestNonRefundable .
cd e2e && go test -race -v -timeout 30m -run TestNonRefundable .

###############################################################################
### Linting ###
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import (
"time"

"cosmossdk.io/math"
transfertypes "github.com/cosmos/ibc-go/v8/modules/apps/transfer/types"
chantypes "github.com/cosmos/ibc-go/v8/modules/core/04-channel/types"
transfertypes "github.com/cosmos/ibc-go/v10/modules/apps/transfer/types"
chantypes "github.com/cosmos/ibc-go/v10/modules/core/04-channel/types"
"github.com/strangelove-ventures/interchaintest/v8"
"github.com/strangelove-ventures/interchaintest/v8/chain/cosmos"
"github.com/strangelove-ventures/interchaintest/v8/ibc"
Expand Down Expand Up @@ -62,10 +62,9 @@ func TestTimeoutOnForward(t *testing.T) {
chainA, chainB, chainC, chainD := chains[0].(*cosmos.CosmosChain), chains[1].(*cosmos.CosmosChain), chains[2].(*cosmos.CosmosChain), chains[3].(*cosmos.CosmosChain)

r := interchaintest.NewBuiltinRelayerFactory(
ibc.CosmosRly,
ibc.Hermes,
zaptest.NewLogger(t),
relayer.DockerImage(&DefaultRelayer),
relayer.StartupFlags("--processor", "events", "--block-history", "100"),
).Build(t, client, network)

const pathAB = "ab"
Expand Down
272 changes: 119 additions & 153 deletions middleware/packet-forward-middleware/e2e/go.mod

Large diffs are not rendered by default.

652 changes: 266 additions & 386 deletions middleware/packet-forward-middleware/e2e/go.sum

Large diffs are not rendered by default.

Loading

0 comments on commit 625908c

Please sign in to comment.